diff options
author | Robert Pösel <robyer@seznam.cz> | 2013-05-17 15:06:51 +0000 |
---|---|---|
committer | Robert Pösel <robyer@seznam.cz> | 2013-05-17 15:06:51 +0000 |
commit | 1c917ac3f485ffac7b4316d633a344fbafcedb78 (patch) | |
tree | 32a83a846c37fc3e3551624bf9ed1ac2e75f8165 /protocols/FacebookRM/src/dialogs.cpp | |
parent | df406e92b92925501b224a01962ef9e9dee84d3b (diff) |
Facebook: Ability to open links on different server (mobile, touch,...).
git-svn-id: http://svn.miranda-ng.org/main/trunk@4702 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/FacebookRM/src/dialogs.cpp')
-rw-r--r-- | protocols/FacebookRM/src/dialogs.cpp | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/protocols/FacebookRM/src/dialogs.cpp b/protocols/FacebookRM/src/dialogs.cpp index f27adefe2e..4f4ee0a581 100644 --- a/protocols/FacebookRM/src/dialogs.cpp +++ b/protocols/FacebookRM/src/dialogs.cpp @@ -38,7 +38,7 @@ static BOOL StoreDBCheckState(FacebookProto* ppro, HWND hwnd, int idCtrl, const INT_PTR CALLBACK FBAccountProc(HWND hwnd, UINT message, WPARAM wparam, LPARAM lparam)
{
- FacebookProto *proto;
+ FacebookProto *proto = reinterpret_cast<FacebookProto*>(GetWindowLongPtr(hwnd,GWLP_USERDATA));
switch (message)
{
@@ -73,8 +73,7 @@ INT_PTR CALLBACK FBAccountProc(HWND hwnd, UINT message, WPARAM wparam, LPARAM lp case WM_COMMAND:
if (LOWORD(wparam) == IDC_NEWACCOUNTLINK)
{
- CallService(MS_UTILS_OPENURL,1,reinterpret_cast<LPARAM>
- (FACEBOOK_URL_HOMEPAGE));
+ proto->OpenUrl(std::string(FACEBOOK_URL_HOMEPAGE));
return TRUE;
}
@@ -92,7 +91,6 @@ INT_PTR CALLBACK FBAccountProc(HWND hwnd, UINT message, WPARAM wparam, LPARAM lp case WM_NOTIFY:
if (reinterpret_cast<NMHDR*>(lparam)->code == PSN_APPLY)
{
- proto = reinterpret_cast<FacebookProto*>(GetWindowLongPtr(hwnd,GWLP_USERDATA));
char str[128];
GetDlgItemTextA(hwnd,IDC_UN,str,sizeof(str));
@@ -229,11 +227,11 @@ INT_PTR CALLBACK FBOptionsProc(HWND hwnd, UINT message, WPARAM wparam, LPARAM lp } return TRUE;
- case WM_COMMAND: {
+ case WM_COMMAND:
+ {
if (LOWORD(wparam) == IDC_NEWACCOUNTLINK)
{
- CallService(MS_UTILS_OPENURL,1,reinterpret_cast<LPARAM>
- (FACEBOOK_URL_HOMEPAGE));
+ proto->OpenUrl(std::string(FACEBOOK_URL_HOMEPAGE));
return TRUE;
}
|