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

Side by Side Diff: chrome/browser/chromeos/extensions/file_manager_util.cc

Issue 10332071: Pass command line arguments onto platform apps which provide the right intent. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Compile fixed, postResult added Created 8 years, 7 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "chrome/browser/chromeos/extensions/file_manager_util.h" 4 #include "chrome/browser/chromeos/extensions/file_manager_util.h"
5 5
6 #include "base/bind.h" 6 #include "base/bind.h"
7 #include "base/file_util.h" 7 #include "base/file_util.h"
8 #include "base/json/json_reader.h" 8 #include "base/json/json_reader.h"
9 #include "base/json/json_writer.h" 9 #include "base/json/json_writer.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 455 matching lines...) Expand 10 before | Expand all | Expand 10 after
466 const Extension* extension = 466 const Extension* extension =
467 service->GetExtensionById(kFileBrowserDomain, false); 467 service->GetExtensionById(kFileBrowserDomain, false);
468 if (!extension) 468 if (!extension)
469 return; 469 return;
470 470
471 extension_misc::LaunchContainer launch_container = 471 extension_misc::LaunchContainer launch_container =
472 service->extension_prefs()-> 472 service->extension_prefs()->
473 GetLaunchContainer(extension, ExtensionPrefs::LAUNCH_DEFAULT); 473 GetLaunchContainer(extension, ExtensionPrefs::LAUNCH_DEFAULT);
474 474
475 content::RecordAction(UserMetricsAction("ShowFileBrowserFullTab")); 475 content::RecordAction(UserMetricsAction("ShowFileBrowserFullTab"));
476 Browser::OpenApplication( 476 Browser::OpenApplication(profile, extension, launch_container,
477 profile, extension, launch_container, GURL(url), NEW_FOREGROUND_TAB); 477 GURL(url), NEW_FOREGROUND_TAB, NULL);
478 } 478 }
479 479
480 void ViewRemovableDrive(const FilePath& path) { 480 void ViewRemovableDrive(const FilePath& path) {
481 OpenFileBrowser(path, REUSE_ANY_FILE_MANAGER, "mountTriggered"); 481 OpenFileBrowser(path, REUSE_ANY_FILE_MANAGER, "mountTriggered");
482 } 482 }
483 483
484 void ShowFileInFolder(const FilePath& path) { 484 void ShowFileInFolder(const FilePath& path) {
485 // This action changes the selection so we do not reuse existing tabs. 485 // This action changes the selection so we do not reuse existing tabs.
486 OpenFileBrowser(path, REUSE_NEVER, "selectOnly"); 486 OpenFileBrowser(path, REUSE_NEVER, "selectOnly");
487 } 487 }
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after
726 GDataOperationRegistry::ProgressStatus>::const_iterator iter = 726 GDataOperationRegistry::ProgressStatus>::const_iterator iter =
727 list.begin(); 727 list.begin();
728 iter != list.end(); ++iter) { 728 iter != list.end(); ++iter) {
729 result_list->Append( 729 result_list->Append(
730 ProgessStatusToDictionaryValue(profile, origin_url, *iter)); 730 ProgessStatusToDictionaryValue(profile, origin_url, *iter));
731 } 731 }
732 return result_list.release(); 732 return result_list.release();
733 } 733 }
734 734
735 } // namespace file_manager_util 735 } // namespace file_manager_util
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698