diff options
Diffstat (limited to 'chrome_frame')
-rw-r--r-- | chrome_frame/chrome_frame_npapi.cc | 10 | ||||
-rw-r--r-- | chrome_frame/chrome_frame_npapi.h | 1 |
2 files changed, 11 insertions, 0 deletions
diff --git a/chrome_frame/chrome_frame_npapi.cc b/chrome_frame/chrome_frame_npapi.cc index 3524335..a4079ca 100644 --- a/chrome_frame/chrome_frame_npapi.cc +++ b/chrome_frame/chrome_frame_npapi.cc @@ -1440,6 +1440,16 @@ bool ChromeFrameNPAPI::GetBrowserIncognitoMode() { return incognito_mode; } +bool ChromeFrameNPAPI::PreProcessContextMenu(HMENU menu) { + // TODO: Remove this overridden method once HandleContextMenuCommand + // implements "About Chrome Frame" handling. + if (!is_privileged_) { + // Call base class (adds 'About' item). + return ChromeFramePlugin::PreProcessContextMenu(menu); + } + return true; +} + bool ChromeFrameNPAPI::HandleContextMenuCommand(UINT cmd, const IPC::ContextMenuParams& params) { if (cmd == IDC_ABOUT_CHROME_FRAME) { diff --git a/chrome_frame/chrome_frame_npapi.h b/chrome_frame/chrome_frame_npapi.h index 994b178..45ee1b9 100644 --- a/chrome_frame/chrome_frame_npapi.h +++ b/chrome_frame/chrome_frame_npapi.h @@ -126,6 +126,7 @@ END_MSG_MAP() // Initialize string->identifier mapping, public to allow unittesting. static void InitializeIdentifiers(); + bool PreProcessContextMenu(HMENU menu); bool HandleContextMenuCommand(UINT cmd, const IPC::ContextMenuParams& params); protected: // Handler for accelerator messages passed on from the hosted chrome |