diff options
author | Alexander Lantsev <aunsane@gmail.com> | 2015-09-02 19:24:27 +0000 |
---|---|---|
committer | Alexander Lantsev <aunsane@gmail.com> | 2015-09-02 19:24:27 +0000 |
commit | 22c79dbeea18dc46951445476976d8c634dd3c60 (patch) | |
tree | 800d9b5ec3a779733e614860701d7295760d0b98 /plugins/Dropbox/src | |
parent | 8a169dcdeaf4dd6455147453dc45c1929a3bc239 (diff) |
Dropbox: code cleanup & menu uid
git-svn-id: http://svn.miranda-ng.org/main/trunk@15157 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Dropbox/src')
-rw-r--r-- | plugins/Dropbox/src/dropbox.h | 2 | ||||
-rw-r--r-- | plugins/Dropbox/src/dropbox_events.cpp | 2 | ||||
-rw-r--r-- | plugins/Dropbox/src/dropbox_menus.cpp | 1 | ||||
-rw-r--r-- | plugins/Dropbox/src/dropbox_utils.cpp | 7 |
4 files changed, 6 insertions, 6 deletions
diff --git a/plugins/Dropbox/src/dropbox.h b/plugins/Dropbox/src/dropbox.h index 31167ff7aa..709ea649fe 100644 --- a/plugins/Dropbox/src/dropbox.h +++ b/plugins/Dropbox/src/dropbox.h @@ -117,7 +117,7 @@ private: void SendToContact(MCONTACT hContact, const char* data);
void PasteToInputArea(MCONTACT hContact, const char* data);
- void PasteToClipboard(MCONTACT hContact, const char* data);
+ void PasteToClipboard(const char* data);
void Report(MCONTACT hContact, const char* data);
template<int(CDropbox::*Event)(WPARAM, LPARAM)>
diff --git a/plugins/Dropbox/src/dropbox_events.cpp b/plugins/Dropbox/src/dropbox_events.cpp index 1ee5fe72d9..dd7ad44426 100644 --- a/plugins/Dropbox/src/dropbox_events.cpp +++ b/plugins/Dropbox/src/dropbox_events.cpp @@ -79,7 +79,7 @@ int CDropbox::OnSrmmWindowOpened(WPARAM, LPARAM lParam) bbd.pszModuleName = MODULE;
bbd.dwButtonID = BBB_ID_FILE_SEND;
bbd.bbbFlags = BBSF_RELEASED;
- if (!HasAccessToken() || ev->hContact == GetDefaultContact() || !HasAccessToken())
+ if (!HasAccessToken() || ev->hContact == GetDefaultContact())
bbd.bbbFlags = BBSF_HIDDEN | BBSF_DISABLED;
else if (!isProtoOnline || (status == ID_STATUS_OFFLINE && !canSendOffline))
bbd.bbbFlags = BBSF_DISABLED;
diff --git a/plugins/Dropbox/src/dropbox_menus.cpp b/plugins/Dropbox/src/dropbox_menus.cpp index d9a0a13555..4740d75570 100644 --- a/plugins/Dropbox/src/dropbox_menus.cpp +++ b/plugins/Dropbox/src/dropbox_menus.cpp @@ -16,6 +16,7 @@ INT_PTR CDropbox::SendFilesToDropboxCommand(void *obj, WPARAM hContact, LPARAM) void CDropbox::InitializeMenus()
{
CMenuItem mi;
+ SET_UID(mi, 0x19af0aaf, 0x37d0, 0x4b88, 0xa5, 0x92, 0xf1, 0x6f, 0x54, 0xfd, 0x67, 0xb5);
mi.pszService = MODULE"/SendFilesToDropbox";
mi.name.a = LPGEN("Upload files to Dropbox");
mi.position = -2000020000 + CMI_SEND_FILES;
diff --git a/plugins/Dropbox/src/dropbox_utils.cpp b/plugins/Dropbox/src/dropbox_utils.cpp index b5e837878d..252f2ad607 100644 --- a/plugins/Dropbox/src/dropbox_utils.cpp +++ b/plugins/Dropbox/src/dropbox_utils.cpp @@ -61,8 +61,7 @@ void CDropbox::SendToContact(MCONTACT hContact, const char* data) }
const char *szProto = GetContactProto(hContact);
- bool isChatRoom = db_get_b(hContact, szProto, "ChatRoom", 0);
- if (isChatRoom)
+ if (db_get_b(hContact, szProto, "ChatRoom", 0) == TRUE)
{
ptrT tszChatRoom(db_get_tsa(hContact, szProto, "ChatRoomID"));
GCDEST gcd = { szProto, tszChatRoom, GC_EVENT_SENDMESSAGE };
@@ -96,7 +95,7 @@ void CDropbox::PasteToInputArea(MCONTACT hContact, const char* data) }
}
-void CDropbox::PasteToClipboard(MCONTACT hContact, const char* data)
+void CDropbox::PasteToClipboard(const char* data)
{
if (OpenClipboard(NULL))
{
@@ -126,5 +125,5 @@ void CDropbox::Report(MCONTACT hContact, const char* data) PasteToInputArea(hContact, data);
if (db_get_b(NULL, MODULE, "UrlCopyToClipboard", 0))
- PasteToClipboard(hContact, data);
+ PasteToClipboard(data);
}
|