diff options
author | relves | 2008-06-04 20:36:04 +0000 |
---|---|---|
committer | relves | 2008-06-04 20:36:04 +0000 |
commit | e2f0b09bf1ead3b755d425a170d8440d70c11dc6 (patch) | |
tree | b063b5a7b164f2cf7b9df87997fdab35a0c1c819 /org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/util | |
parent | 3bb357e4a582431fe8c1d8f9f00cd61204c84795 (diff) | |
download | org.eclipse.mylyn.tasks-e2f0b09bf1ead3b755d425a170d8440d70c11dc6.tar.gz org.eclipse.mylyn.tasks-e2f0b09bf1ead3b755d425a170d8440d70c11dc6.tar.xz org.eclipse.mylyn.tasks-e2f0b09bf1ead3b755d425a170d8440d70c11dc6.zip |
NEW - bug 228249: include active working set in task activity events
https://bugs.eclipse.org/bugs/show_bug.cgi?id=228249
Diffstat (limited to 'org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/util')
-rw-r--r-- | org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/util/BackgroundSaveTimer.java | 100 |
1 files changed, 0 insertions, 100 deletions
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/util/BackgroundSaveTimer.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/util/BackgroundSaveTimer.java deleted file mode 100644 index 1caff5e28..000000000 --- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/util/BackgroundSaveTimer.java +++ /dev/null @@ -1,100 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2004, 2007 Mylyn project committers and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - *******************************************************************************/ -package org.eclipse.mylyn.internal.tasks.ui.util; - -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Status; -import org.eclipse.mylyn.commons.core.StatusHandler; -import org.eclipse.mylyn.internal.tasks.ui.TasksUiPlugin; -import org.eclipse.mylyn.monitor.core.ActivityTimerThread; -import org.eclipse.mylyn.monitor.core.IActivityTimerListener; - -/** - * Timer that periodically runs saveRequested() on its client as a job - * - * @author Wesley Coelho - */ -public class BackgroundSaveTimer implements IActivityTimerListener { - - private final static int DEFAULT_SAVE_INTERVAL = 60 * 1000; - - private int saveInterval = DEFAULT_SAVE_INTERVAL; - - private IBackgroundSaveListener listener = null; - - private ActivityTimerThread timer = null; - -// private boolean forceSyncExec = false; - - public BackgroundSaveTimer(IBackgroundSaveListener listener) { - this.listener = listener; - timer = new ActivityTimerThread(saveInterval); - timer.addListener(this); - } - - public void start() { - timer.start(); - } - - public void stop() { - timer.kill(); - } - - public void setSaveIntervalMillis(int saveIntervalMillis) { - this.saveInterval = saveIntervalMillis; - timer.setTimeoutMillis(saveIntervalMillis); - } - - public int getSaveIntervalMillis() { - return saveInterval; - } - -// /** -// * For testing -// */ -// public void setForceSyncExec(boolean forceSyncExec) { -// this.forceSyncExec = forceSyncExec; -// } - - /** - * Called by the ActivityTimerThread Calls save in a new job - */ - public void fireInactive() { - try { -// if (!forceSyncExec) { -// final SaveJob job = new SaveJob("Saving Task Data", listener); -// job.schedule(); -// } else { - listener.saveRequested(); -// } - } catch (RuntimeException e) { - StatusHandler.log(new Status(IStatus.WARNING, TasksUiPlugin.ID_PLUGIN, "Could not schedule save job", e)); - } - } - -// /** Job that makes the save call */ -// private class SaveJob extends Job { -// private IBackgroundSaveListener listener = null; -// -// public SaveJob(String name, IBackgroundSaveListener listener) { -// super(name); -// this.listener = listener; -// } -// -// @Override -// protected IStatus run(IProgressMonitor monitor) { -// listener.saveRequested(); -// return Status.OK_STATUS; -// } -// } - - public void fireActive(long start, long end) { - // ignore - } - -} |