diff options
author | sje <sje@4f64403b-2f21-0410-a795-97e2b3489a10> | 2007-07-31 03:03:47 +0000 |
---|---|---|
committer | sje <sje@4f64403b-2f21-0410-a795-97e2b3489a10> | 2007-07-31 03:03:47 +0000 |
commit | 87a314a0f8b3aa138601963c0e98d339997b9d6e (patch) | |
tree | 11b2e0bde77f236bd7a7b9db434c8f28e84d93f2 | |
parent | cb844f4914564d0027a836bb089f0c34819de2c2 (diff) |
add beta changelog url link to svn log
start thread in modules loaded event (fix for possible freeze on startup)
git-svn-id: https://server.scottellis.com.au/svn/mim_plugs@315 4f64403b-2f21-0410-a795-97e2b3489a10
-rw-r--r-- | last_contact/LastContact.cpp | 78 |
1 files changed, 39 insertions, 39 deletions
diff --git a/last_contact/LastContact.cpp b/last_contact/LastContact.cpp index 7c12908..9366daf 100644 --- a/last_contact/LastContact.cpp +++ b/last_contact/LastContact.cpp @@ -54,7 +54,7 @@ void stack_update(MessageWindowEventData *data) { PLUGININFOEX pluginInfo={
sizeof(PLUGININFOEX),
MODULE,
- PLUGIN_MAKE_VERSION(0,0,2,2),
+ PLUGIN_MAKE_VERSION(0,0,2,3),
"Re-open the last open message window using a configurable hot key.",
"Scott Ellis",
"mail@scottellis.com.au",
@@ -116,43 +116,6 @@ int WindowEvent(WPARAM wParam, LPARAM lParam) { return 0;
}
-int ModulesLoaded(WPARAM wParam,LPARAM lParam) {
- if(ServiceExists(MS_UPDATE_REGISTER)) {
- // register with updater
- Update update = {0};
- char szVersion[16];
-
- update.cbSize = sizeof(Update);
-
- update.szComponentName = pluginInfo.shortName;
- update.pbVersion = (BYTE *)CreateVersionString(pluginInfo.version, szVersion);
- update.cpbVersion = strlen((char *)update.pbVersion);
-
- update.szUpdateURL = UPDATER_AUTOREGISTER;
-
- // these are the three lines that matter - the archive, the page containing the version string, and the text (or data)
- // before the version that we use to locate it on the page
- // (note that if the update URL and the version URL point to standard file listing entries, the backend xml
- // data will be used to check for updates rather than the actual web page - this is not true for beta urls)
- update.szBetaUpdateURL = "http://www.scottellis.com.au/miranda_plugins/last_contact.zip";
- update.szBetaVersionURL = "http://www.scottellis.com.au/miranda_plugins/ver_last_contact.html";
- update.pbBetaVersionPrefix = (BYTE *)MODULE " version ";
-
- update.cpbBetaVersionPrefix = strlen((char *)update.pbBetaVersionPrefix);
-
- CallService(MS_UPDATE_REGISTER, 0, (WPARAM)&update);
- }
-
- hEventWindow = HookEvent(ME_MSG_WINDOWEVENT, WindowEvent);
-
- return 0;
-}
-
-int Shutdown(WPARAM wParam, LPARAM lParam) {
- if(hEventWindow) UnhookEvent(hEventWindow);
- return 0;
-}
-
void HotkeyAction() {
MessageWindowEventData wd;
if(stack_pop(&wd)) {
@@ -197,6 +160,44 @@ void EventLoop(HANDLE hEvent) { UnregisterHotKey(0, hotkey_id);
}
+int ModulesLoaded(WPARAM wParam,LPARAM lParam) {
+ if(ServiceExists(MS_UPDATE_REGISTER)) {
+ // register with updater
+ Update update = {0};
+ char szVersion[16];
+
+ update.cbSize = sizeof(Update);
+
+ update.szComponentName = pluginInfo.shortName;
+ update.pbVersion = (BYTE *)CreateVersionString(pluginInfo.version, szVersion);
+ update.cpbVersion = strlen((char *)update.pbVersion);
+ update.szBetaChangelogURL = "https://server.scottellis.com.au/websvn/log.php?repname=Miranda+Plugins&path=%2Flast_contact%2F&rev=0&sc=0&isdir=1";
+
+ update.szUpdateURL = UPDATER_AUTOREGISTER;
+
+ // these are the three lines that matter - the archive, the page containing the version string, and the text (or data)
+ // before the version that we use to locate it on the page
+ // (note that if the update URL and the version URL point to standard file listing entries, the backend xml
+ // data will be used to check for updates rather than the actual web page - this is not true for beta urls)
+ update.szBetaUpdateURL = "http://www.scottellis.com.au/miranda_plugins/last_contact.zip";
+ update.szBetaVersionURL = "http://www.scottellis.com.au/miranda_plugins/ver_last_contact.html";
+ update.pbBetaVersionPrefix = (BYTE *)MODULE " version ";
+
+ update.cpbBetaVersionPrefix = strlen((char *)update.pbBetaVersionPrefix);
+
+ CallService(MS_UPDATE_REGISTER, 0, (WPARAM)&update);
+ }
+
+ mir_forkthread(EventLoop, 0);
+ hEventWindow = HookEvent(ME_MSG_WINDOWEVENT, WindowEvent);
+ return 0;
+}
+
+int Shutdown(WPARAM wParam, LPARAM lParam) {
+ if(hEventWindow) UnhookEvent(hEventWindow);
+ return 0;
+}
+
UINT_PTR timer_id;
extern "C" int __declspec(dllexport) Load(PLUGINLINK *link)
@@ -211,7 +212,6 @@ extern "C" int __declspec(dllexport) Load(PLUGINLINK *link) InitOptions();
hotkey_id = GlobalAddAtom(MAKEINTATOM(1));
- mir_forkthread(EventLoop, 0);
return 0;
}
|