Chromium Code Reviews| Index: blimp/client/app/linux/blimp_client_session_linux.cc |
| diff --git a/blimp/client/app/linux/blimp_client_session_linux.cc b/blimp/client/app/linux/blimp_client_session_linux.cc |
| index 66ab8ed9504c0779da06ee05ea64b4f85e2094f0..42952e260aac705218f0b985bfbf5c7b314aeed8 100644 |
| --- a/blimp/client/app/linux/blimp_client_session_linux.cc |
| +++ b/blimp/client/app/linux/blimp_client_session_linux.cc |
| @@ -18,7 +18,7 @@ namespace client { |
| namespace { |
| const int kDummyTabId = 0; |
| -const std::string kDefaultAssignerUrl = |
| +const char kDefaultAssignerUrl[] = |
|
xyzzyz
2016/05/31 17:11:08
There's a script that catches these: https://code.
Wez
2016/06/02 17:38:32
Acknowledged.
|
| "https://blimp-pa.googleapis.com/v1/assignment"; |
| class FakeNavigationFeatureDelegate |
| @@ -66,18 +66,47 @@ void FakeNavigationFeatureDelegate::OnPageLoadStatusUpdate(int tab_id, |
| " in tab " << tab_id; |
| } |
| +class FakeImeFeatureDelegate : public ImeFeature::Delegate { |
| + public: |
| + FakeImeFeatureDelegate(); |
| + ~FakeImeFeatureDelegate() override; |
| + |
| + // ImeFeature::Delegate implementation. |
| + void OnShowImeRequested(ui::TextInputType input_type, |
| + const std::string& text) override; |
| + void OnHideImeRequested() override; |
| + |
| + private: |
| + DISALLOW_COPY_AND_ASSIGN(FakeImeFeatureDelegate); |
| +}; |
| + |
| +FakeImeFeatureDelegate::FakeImeFeatureDelegate() {} |
| + |
| +FakeImeFeatureDelegate::~FakeImeFeatureDelegate() {} |
| + |
| +void FakeImeFeatureDelegate::OnShowImeRequested(ui::TextInputType input_type, |
| + const std::string& text) { |
| + DVLOG(1) << "Show IME requested (input_type=" << input_type << ")"; |
| +} |
| + |
| +void FakeImeFeatureDelegate::OnHideImeRequested() { |
| + DVLOG(1) << "Hide IME requested"; |
| +} |
| + |
| } // namespace |
| BlimpClientSessionLinux::BlimpClientSessionLinux() |
| : BlimpClientSession(GURL(kDefaultAssignerUrl)), |
| event_source_(ui::PlatformEventSource::CreateDefault()), |
| - navigation_feature_delegate_(new FakeNavigationFeatureDelegate) { |
| + navigation_feature_delegate_(new FakeNavigationFeatureDelegate), |
| + ime_feature_delegate_(new FakeImeFeatureDelegate) { |
| blimp_display_manager_.reset(new BlimpDisplayManager(gfx::Size(800, 600), |
| this, |
| GetRenderWidgetFeature(), |
| GetTabControlFeature())); |
| GetNavigationFeature()->SetDelegate(kDummyTabId, |
| navigation_feature_delegate_.get()); |
| + GetImeFeature()->set_delegate(ime_feature_delegate_.get()); |
|
xyzzyz
2016/05/31 17:11:08
The above SetDelegate is CamelCase. We should be c
Wez
2016/06/02 17:38:33
Yeah, that bothered me as well.
The set_delegate(
|
| } |
| BlimpClientSessionLinux::~BlimpClientSessionLinux() {} |