Left: | ||
Right: |
OLD | NEW |
---|---|
1 #include "PluginStdAfx.h" | 1 #include "PluginStdAfx.h" |
2 | 2 |
3 #include "PluginClass.h" | 3 #include "PluginClass.h" |
4 #include "PluginDictionary.h" | 4 #include "PluginDictionary.h" |
5 #include "PluginSettings.h" | 5 #include "PluginSettings.h" |
6 #include "PluginSystem.h" | 6 #include "PluginSystem.h" |
7 #ifdef SUPPORT_FILTER | 7 #ifdef SUPPORT_FILTER |
8 #include "PluginFilter.h" | 8 #include "PluginFilter.h" |
9 #endif | 9 #endif |
10 #include "PluginMimeFilterClient.h" | 10 #include "PluginMimeFilterClient.h" |
(...skipping 556 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
567 settings->Write(); | 567 settings->Write(); |
568 | 568 |
569 HKEY pHkey; | 569 HKEY pHkey; |
570 HKEY pHkeySub; | 570 HKEY pHkeySub; |
571 LSTATUS regRes = 0; | 571 LSTATUS regRes = 0; |
572 regRes = RegOpenCurrentUser(KEY_WRITE, &pHkey); | 572 regRes = RegOpenCurrentUser(KEY_WRITE, &pHkey); |
573 | 573 |
574 // Do we have enough rights to enable a status bar? | 574 // Do we have enough rights to enable a status bar? |
575 if (regRes != 0) | 575 if (regRes != 0) |
576 { | 576 { |
577 LPCWSTR browserVersion = CPluginSystem::GetInstance()->GetBrowserVer sion(); | |
578 int versionNumber = wcstol(browserVersion, 0, 10); | |
Felix Dahlke
2013/06/07 06:28:24
@Oleksandr:
Can I rely on this being an integer? I
Oleksandr
2013/06/07 07:16:46
This is guaranteed to be either 1 number or an emp
Felix Dahlke
2013/06/07 08:02:47
Hm, I thought it was shown by default in IE8. But
Wladimir Palant
2013/06/07 08:48:29
I looked through the IE versions:
* Custom title
| |
579 LPCSTR messageKey = versionNumber >= 9 ? "ERROR_CAN_NOT_ENABLE_STATU S_BAR_IE9" : "ERROR_CAN_NOT_ENABLE_STATUS_BAR"; | |
577 // We use the tab window here and in the next few calls, since the b rowser window may still not be available | 580 // We use the tab window here and in the next few calls, since the b rowser window may still not be available |
578 LRESULT res = MessageBox((HWND)m_hTabWnd, dictionary->Lookup("ERROR_ CAN_NOT_ENABLE_STATUS_BAR"), | 581 LRESULT res = MessageBox((HWND)m_hTabWnd, dictionary->Lookup(message Key), |
579 dictionary->Lookup("ERROR_CAN_NOT_ENABLE_STATUS_BAR_TITLE"), MB_OK ); | 582 dictionary->Lookup("ERROR_CAN_NOT_ENABLE_STATUS_BAR_TITLE"), MB_OK ); |
580 return; | 583 return; |
581 } | 584 } |
582 // Ask if a user wants to enable a status bar automatically | 585 // Ask if a user wants to enable a status bar automatically |
583 LRESULT res = MessageBox((HWND)m_hTabWnd, dictionary->Lookup("ERROR_ST ATUS_BAR_DISABLED"), | 586 LRESULT res = MessageBox((HWND)m_hTabWnd, dictionary->Lookup("ERROR_ST ATUS_BAR_DISABLED"), |
584 dictionary->Lookup("ERROR_STATUS_BAR_DISABLED_TITLE"), MB_YESNO); | 587 dictionary->Lookup("ERROR_STATUS_BAR_DISABLED_TITLE"), MB_YESNO); |
585 if (res == IDYES) | 588 if (res == IDYES) |
586 { | 589 { |
587 DWORD trueth = 1; | 590 DWORD trueth = 1; |
588 regRes = RegOpenKey(pHkey, L"Software\\Microsoft\\Internet Explorer\ \MINIE", &pHkeySub); | 591 regRes = RegOpenKey(pHkey, L"Software\\Microsoft\\Internet Explorer\ \MINIE", &pHkeySub); |
(...skipping 1624 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2213 } | 2216 } |
2214 } | 2217 } |
2215 } | 2218 } |
2216 | 2219 |
2217 hTabWnd = ::GetWindow(hTabWnd, GW_HWNDNEXT); | 2220 hTabWnd = ::GetWindow(hTabWnd, GW_HWNDNEXT); |
2218 } | 2221 } |
2219 | 2222 |
2220 return hTabWnd; | 2223 return hTabWnd; |
2221 | 2224 |
2222 } | 2225 } |
OLD | NEW |