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

Side by Side Diff: athena/content/web_activity.cc

Issue 825473002: Make callers of CommandLine use it via the base:: namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 12 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 unified diff | Download patch
« no previous file with comments | « ash/virtual_keyboard_controller_unittest.cc ('k') | chromeos/dbus/dbus_client_bundle.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "athena/content/web_activity.h" 5 #include "athena/content/web_activity.h"
6 6
7 #include "athena/activity/public/activity_factory.h" 7 #include "athena/activity/public/activity_factory.h"
8 #include "athena/activity/public/activity_manager.h" 8 #include "athena/activity/public/activity_manager.h"
9 #include "athena/activity/public/activity_view.h" 9 #include "athena/activity/public/activity_view.h"
10 #include "athena/content/content_proxy.h" 10 #include "athena/content/content_proxy.h"
(...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after
262 break; 262 break;
263 } 263 }
264 default: 264 default:
265 break; 265 break;
266 } 266 }
267 // nullptr is returned if the URL wasn't opened immediately. 267 // nullptr is returned if the URL wasn't opened immediately.
268 return nullptr; 268 return nullptr;
269 } 269 }
270 270
271 bool CanOverscrollContent() const override { 271 bool CanOverscrollContent() const override {
272 const std::string value = CommandLine::ForCurrentProcess()-> 272 const std::string value =
273 GetSwitchValueASCII(switches::kOverscrollHistoryNavigation); 273 base::CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
274 switches::kOverscrollHistoryNavigation);
274 return value != "0"; 275 return value != "0";
275 } 276 }
276 277
277 void OverscrollUpdate(float delta_y) override { 278 void OverscrollUpdate(float delta_y) override {
278 overscroll_y_ = delta_y; 279 overscroll_y_ = delta_y;
279 if (overscroll_y_ > kDistanceShowReloadMessage) { 280 if (overscroll_y_ > kDistanceShowReloadMessage) {
280 if (!reload_message_) 281 if (!reload_message_)
281 CreateReloadMessage(); 282 CreateReloadMessage();
282 reload_message_->Show(); 283 reload_message_->Show();
283 float opacity = 1.0f; 284 float opacity = 1.0f;
(...skipping 367 matching lines...) Expand 10 before | Expand all | Expand 10 after
651 if (content_proxy_.get()) 652 if (content_proxy_.get())
652 content_proxy_.reset(nullptr); 653 content_proxy_.reset(nullptr);
653 } 654 }
654 655
655 void WebActivity::ShowContentProxy() { 656 void WebActivity::ShowContentProxy() {
656 if (!content_proxy_.get()) 657 if (!content_proxy_.get())
657 content_proxy_.reset(new ContentProxy(web_view_)); 658 content_proxy_.reset(new ContentProxy(web_view_));
658 } 659 }
659 660
660 } // namespace athena 661 } // namespace athena
OLDNEW
« no previous file with comments | « ash/virtual_keyboard_controller_unittest.cc ('k') | chromeos/dbus/dbus_client_bundle.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698