[Scummvm-cvs-logs] scummvm master -> e978a6afb7de89a00b5b5485727879fdd3d706f4
Littleboy
littleboy22 at gmail.com
Sat Aug 6 21:41:56 CEST 2011
This automated email contains information about 3 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
539bf5317f COMMON: Add notifyError() and clearError() to the TaskbarManager, used to notify the user that an error happened through
f702cb5695 BACKENDS: Implement notifyError() and clearError() for Win32TaskbarManager
e978a6afb7 ENGINES: Use the new taskbar error notification methods in the engines defaultErrorHandler()
Commit: 539bf5317feadcf34578dee953dce89ef4bdef4a
https://github.com/scummvm/scummvm/commit/539bf5317feadcf34578dee953dce89ef4bdef4a
Author: Littleboy (littleboy at scummvm.org)
Date: 2011-08-06T12:25:32-07:00
Commit Message:
COMMON: Add notifyError() and clearError() to the TaskbarManager, used to notify the user that an error happened through the taskbar icon
Changed paths:
common/taskbar.h
diff --git a/common/taskbar.h b/common/taskbar.h
index 36d5e33..ba99d4e 100644
--- a/common/taskbar.h
+++ b/common/taskbar.h
@@ -122,6 +122,18 @@ public:
*/
virtual void addRecent(const String &name, const String &description) {}
+ /**
+ * Notifies the user an error occured through the taskbar icon
+ *
+ * This will for example show the taskbar icon as red (using progress of 100% and an error state)
+ * on Windows, and set the launcher icon in the urgent state on Unity
+ */
+ virtual void notifyError() {}
+
+ /**
+ * Clears the error notification
+ */
+ virtual void clearError() {}
};
} // End of namespace Common
Commit: f702cb5695dcec2e14b4ef7f18971cc0b12ebe0e
https://github.com/scummvm/scummvm/commit/f702cb5695dcec2e14b4ef7f18971cc0b12ebe0e
Author: Littleboy (littleboy at scummvm.org)
Date: 2011-08-06T12:26:49-07:00
Commit Message:
BACKENDS: Implement notifyError() and clearError() for Win32TaskbarManager
Changed paths:
backends/taskbar/win32/win32-taskbar.cpp
backends/taskbar/win32/win32-taskbar.h
diff --git a/backends/taskbar/win32/win32-taskbar.cpp b/backends/taskbar/win32/win32-taskbar.cpp
index b1afdf6..046ddb1 100644
--- a/backends/taskbar/win32/win32-taskbar.cpp
+++ b/backends/taskbar/win32/win32-taskbar.cpp
@@ -317,6 +317,15 @@ void Win32TaskbarManager::addRecent(const Common::String &name, const Common::St
}
}
+void Win32TaskbarManager::notifyError() {
+ setProgressState(Common::TaskbarManager::kTaskbarError);
+ setProgressValue(1, 1);
+}
+
+void Win32TaskbarManager::clearError() {
+ setProgressState(kTaskbarNoProgress);
+}
+
Common::String Win32TaskbarManager::getIconPath(Common::String target) {
// We first try to look for a iconspath configuration variable then
// fallback to the extra path
diff --git a/backends/taskbar/win32/win32-taskbar.h b/backends/taskbar/win32/win32-taskbar.h
index d005b0f..36415c1 100644
--- a/backends/taskbar/win32/win32-taskbar.h
+++ b/backends/taskbar/win32/win32-taskbar.h
@@ -40,6 +40,8 @@ public:
virtual void setProgressState(TaskbarProgressState state);
virtual void setCount(int count);
virtual void addRecent(const Common::String &name, const Common::String &description);
+ virtual void notifyError();
+ virtual void clearError();
private:
ITaskbarList3 *_taskbar;
Commit: e978a6afb7de89a00b5b5485727879fdd3d706f4
https://github.com/scummvm/scummvm/commit/e978a6afb7de89a00b5b5485727879fdd3d706f4
Author: Littleboy (littleboy at scummvm.org)
Date: 2011-08-06T12:27:43-07:00
Commit Message:
ENGINES: Use the new taskbar error notification methods in the engines defaultErrorHandler()
Changed paths:
engines/engine.cpp
diff --git a/engines/engine.cpp b/engines/engine.cpp
index 5fc8f62..ee1d53f 100644
--- a/engines/engine.cpp
+++ b/engines/engine.cpp
@@ -80,13 +80,19 @@ static void defaultErrorHandler(const char *msg) {
if (isSmartphone())
debugger = 0;
#endif
+
+#if defined(USE_TASKBAR)
+ g_system->getTaskbarManager()->notifyError();
+#endif
+
if (debugger && !debugger->isActive()) {
debugger->attach(msg);
debugger->onFrame();
}
+
#if defined(USE_TASKBAR)
- g_system->getTaskbarManager()->setProgressState(Common::TaskbarManager::kTaskbarError);
+ g_system->getTaskbarManager()->clearError();
#endif
}
More information about the Scummvm-git-logs
mailing list