Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3346)

Unified Diff: chrome/browser/ui/tab_contents/tab_contents_wrapper.cc

Issue 7715037: Web Intent Picker UI (implemented as a constrained dialog, linux only) (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: linux_views/chromeos fix Created 9 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/tab_contents/tab_contents_wrapper.cc
diff --git a/chrome/browser/ui/tab_contents/tab_contents_wrapper.cc b/chrome/browser/ui/tab_contents/tab_contents_wrapper.cc
index a8d396d17cdb5d50fc9fae27b71952d3dd91a376..7f92a8889eab960d24471d7a5e83f4c69f593975 100644
--- a/chrome/browser/ui/tab_contents/tab_contents_wrapper.cc
+++ b/chrome/browser/ui/tab_contents/tab_contents_wrapper.cc
@@ -54,6 +54,8 @@
#include "chrome/browser/ui/blocked_content/blocked_content_tab_helper.h"
#include "chrome/browser/ui/bookmarks/bookmark_tab_helper.h"
#include "chrome/browser/ui/find_bar/find_tab_helper.h"
+#include "chrome/browser/ui/intents/web_intent_constrained_dialog_factory.h"
+#include "chrome/browser/ui/intents/web_intent_picker_controller.h"
#include "chrome/browser/ui/search_engines/search_engine_tab_helper.h"
#include "chrome/browser/ui/tab_contents/tab_contents_wrapper_delegate.h"
#include "chrome/common/chrome_notification_types.h"
@@ -156,6 +158,9 @@ TabContentsWrapper::TabContentsWrapper(TabContents* contents)
content_settings_.reset(new TabSpecificContentSettings(contents));
translate_tab_helper_.reset(new TranslateTabHelper(contents));
print_view_manager_.reset(new printing::PrintViewManager(this));
+ web_intent_picker_controller_.reset(new WebIntentPickerController(
+ contents,
+ new WebIntentConstrainedDialogFactory()));
// Create the per-tab observers.
external_protocol_observer_.reset(new ExternalProtocolObserver(contents));
@@ -645,6 +650,8 @@ void TabContentsWrapper::OnWebIntentDispatch(const IPC::Message& message,
<< "\ntype=" << UTF16ToASCII(type)
<< "\nrenderer_id=" << message.routing_id()
<< "\nid=" << intent_id;
+
+ web_intent_picker_controller_->ShowDialog(action, type);
}
void TabContentsWrapper::OnSnapshot(const SkBitmap& bitmap) {
« no previous file with comments | « chrome/browser/ui/tab_contents/tab_contents_wrapper.h ('k') | chrome/browser/ui/views/web_intent_picker_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698