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

Side by Side Diff: chrome/browser/download/download_shelf_context_menu.h

Issue 324593004: Windows: Add an "Open in Adobe Reader" menu item for PDF files in the download shelf. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address comments, check AcroRd32.exe version, set/honor prefs Created 6 years, 6 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #ifndef CHROME_BROWSER_DOWNLOAD_DOWNLOAD_SHELF_CONTEXT_MENU_H_ 5 #ifndef CHROME_BROWSER_DOWNLOAD_DOWNLOAD_SHELF_CONTEXT_MENU_H_
6 #define CHROME_BROWSER_DOWNLOAD_DOWNLOAD_SHELF_CONTEXT_MENU_H_ 6 #define CHROME_BROWSER_DOWNLOAD_DOWNLOAD_SHELF_CONTEXT_MENU_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 66
67 // content::DownloadItem::Observer 67 // content::DownloadItem::Observer
68 virtual void OnDownloadDestroyed(content::DownloadItem* download) OVERRIDE; 68 virtual void OnDownloadDestroyed(content::DownloadItem* download) OVERRIDE;
69 69
70 ui::SimpleMenuModel* GetInProgressMenuModel(); 70 ui::SimpleMenuModel* GetInProgressMenuModel();
71 ui::SimpleMenuModel* GetFinishedMenuModel(); 71 ui::SimpleMenuModel* GetFinishedMenuModel();
72 ui::SimpleMenuModel* GetInterruptedMenuModel(); 72 ui::SimpleMenuModel* GetInterruptedMenuModel();
73 ui::SimpleMenuModel* GetMaybeMaliciousMenuModel(); 73 ui::SimpleMenuModel* GetMaybeMaliciousMenuModel();
74 ui::SimpleMenuModel* GetMaliciousMenuModel(); 74 ui::SimpleMenuModel* GetMaliciousMenuModel();
75 75
76 int GetAlwaysOpenStringId() const;
77
78 #if defined(OS_WIN)
79 bool IsDownloadPdf() const;
80 bool CanOpenPdfInReader() const;
81 #endif
82
76 // We show slightly different menus if the download is in progress vs. if the 83 // We show slightly different menus if the download is in progress vs. if the
77 // download has finished. 84 // download has finished.
78 scoped_ptr<ui::SimpleMenuModel> in_progress_download_menu_model_; 85 scoped_ptr<ui::SimpleMenuModel> in_progress_download_menu_model_;
79 scoped_ptr<ui::SimpleMenuModel> finished_download_menu_model_; 86 scoped_ptr<ui::SimpleMenuModel> finished_download_menu_model_;
80 scoped_ptr<ui::SimpleMenuModel> interrupted_download_menu_model_; 87 scoped_ptr<ui::SimpleMenuModel> interrupted_download_menu_model_;
81 scoped_ptr<ui::SimpleMenuModel> maybe_malicious_download_menu_model_; 88 scoped_ptr<ui::SimpleMenuModel> maybe_malicious_download_menu_model_;
82 scoped_ptr<ui::SimpleMenuModel> malicious_download_menu_model_; 89 scoped_ptr<ui::SimpleMenuModel> malicious_download_menu_model_;
83 90
84 // Information source. 91 // Information source.
85 content::DownloadItem* download_item_; 92 content::DownloadItem* download_item_;
86 93
87 // Used to open tabs. 94 // Used to open tabs.
88 content::PageNavigator* navigator_; 95 content::PageNavigator* navigator_;
89 96
97 #if defined(OS_WIN)
98 bool is_pdf_reader_up_to_date_;
99 #endif
100
90 DISALLOW_COPY_AND_ASSIGN(DownloadShelfContextMenu); 101 DISALLOW_COPY_AND_ASSIGN(DownloadShelfContextMenu);
91 }; 102 };
92 103
93 #endif // CHROME_BROWSER_DOWNLOAD_DOWNLOAD_SHELF_CONTEXT_MENU_H_ 104 #endif // CHROME_BROWSER_DOWNLOAD_DOWNLOAD_SHELF_CONTEXT_MENU_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698