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

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

Issue 659113002: Fix window.close() in Athena (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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 | « no previous file | no next file » | 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/content/content_proxy.h" 9 #include "athena/content/content_proxy.h"
10 #include "athena/content/media_utils.h" 10 #include "athena/content/media_utils.h"
(...skipping 352 matching lines...) Expand 10 before | Expand all | Expand 10 after
363 return athena::OpenColorChooser(web_contents, color, suggestions); 363 return athena::OpenColorChooser(web_contents, color, suggestions);
364 } 364 }
365 365
366 // Called when a file selection is to be done. 366 // Called when a file selection is to be done.
367 virtual void RunFileChooser( 367 virtual void RunFileChooser(
368 content::WebContents* web_contents, 368 content::WebContents* web_contents,
369 const content::FileChooserParams& params) override { 369 const content::FileChooserParams& params) override {
370 return athena::OpenFileChooser(web_contents, params); 370 return athena::OpenFileChooser(web_contents, params);
371 } 371 }
372 372
373 virtual void CloseContents(content::WebContents* contents) override {
374 GetWidget()->Close();
oshima 2014/10/16 18:44:48 This may not delete activity. Does the following w
yoshiki 2014/10/16 18:49:58 I'll check whether it works. BTW, should we change
375 }
376
373 private: 377 private:
374 void CreateProgressBar() { 378 void CreateProgressBar() {
375 CHECK(!progress_bar_); 379 CHECK(!progress_bar_);
376 progress_bar_.reset(new ui::Layer(ui::LAYER_SOLID_COLOR)); 380 progress_bar_.reset(new ui::Layer(ui::LAYER_SOLID_COLOR));
377 progress_bar_->SetColor(SkColorSetRGB(0x17, 0x59, 0xcd)); 381 progress_bar_->SetColor(SkColorSetRGB(0x17, 0x59, 0xcd));
378 } 382 }
379 383
380 void CreateReloadMessage() { 384 void CreateReloadMessage() {
381 CHECK(!reload_message_); 385 CHECK(!reload_message_);
382 reload_message_.reset(new views::Widget); 386 reload_message_.reset(new views::Widget);
(...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after
627 if (content_proxy_.get()) 631 if (content_proxy_.get())
628 content_proxy_.reset(NULL); 632 content_proxy_.reset(NULL);
629 } 633 }
630 634
631 void WebActivity::ShowContentProxy() { 635 void WebActivity::ShowContentProxy() {
632 if (!content_proxy_.get()) 636 if (!content_proxy_.get())
633 content_proxy_.reset(new ContentProxy(web_view_)); 637 content_proxy_.reset(new ContentProxy(web_view_));
634 } 638 }
635 639
636 } // namespace athena 640 } // namespace athena
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698