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

Unified Diff: chrome/browser/ui/cocoa/share_menu/share_menu_controller.h

Issue 1105143005: Issue 465302:System wide share options on Mac Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Adds an attachment to Mail Created 5 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/cocoa/share_menu/share_menu_controller.h
diff --git a/chrome/browser/ui/cocoa/share_menu/share_menu_controller.h b/chrome/browser/ui/cocoa/share_menu/share_menu_controller.h
new file mode 100644
index 0000000000000000000000000000000000000000..1792a2e60c877498206115608051a1ead0b0a51d
--- /dev/null
+++ b/chrome/browser/ui/cocoa/share_menu/share_menu_controller.h
@@ -0,0 +1,56 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_UI_COCOA_RENDERER_CONTEXT_SHARE_MENU_CONTROLLER
+#define CHROME_BROWSER_UI_COCOA_RENDERER_CONTEXT_SHARE_MENU_CONTROLLER
+
+#import <Cocoa/Cocoa.h>
+
+#import "base/mac/scoped_nsobject.h"
+#include "base/memory/scoped_ptr.h"
+#include "chrome/browser/ui/browser.h"
+
+static NSString* kPageScreenShot = @"page_screen_shot";
+static NSString* kPageUrl = @"page_url";
+static NSString* kPageHtml = @"page_html";
+
+namespace ShareMenuControllerInternal {
+class Observer;
+}
+
+@interface ShareMenuController : NSObject {
+ @private
+ __weak NSMenu* mainMenu_;
+ scoped_ptr<ShareMenuControllerInternal::Observer> observer_;
+ base::scoped_nsobject<NSMutableArray> shareItems_;
+ NSMenuItem* shareMenuItem_;
+ base::scoped_nsobject<NSMenu> shareSubMenu_;
+ NSMenuItem* fileMenuItem_;
+ BOOL menuItemsLoaded_;
+ NSString* pageUrlForCurrentTab_;
+ base::scoped_nsobject<NSImage> contentSnapShot_;
+ base::scoped_nsobject<NSDictionary> pageInfo_;
+ //base::scoped_nsobject<NSData> pageHtml_;
+ base::scoped_nsobject<NSAttributedString> pageHtml_;
+ base::scoped_nsobject<NSString> page_;
+ base::scoped_nsobject<NSArray> originalSharableItems_;
+ content::WebContents* pageContents_;
+ Browser* lastActiveBrowser_;
+}
+
+- (id)initWithMainMenu:(NSMenu*)menu;
+- (BOOL)menuItemsLoaded;
+- (void)setPageContents:(content::WebContents*)contents;
+- (void)setActiveBrowser:(Browser*)browser;
+- (void)rebuildShareMenu;
+
+@end
+
+@interface ShareMenuController(PrivateShareMenuControllerTesting)
+- (void)initShareMenuItem;
+- (NSMenu*)shareSubMenu;
+- (NSMenuItem*)shareSubMenuItem;
+@end
+
+#endif // CHROME_BROWSER_UI_COCOA_RENDERER_CONTEXT_SHARE_MENU_CONTROLLER
« no previous file with comments | « chrome/browser/ui/browser_command_controller.cc ('k') | chrome/browser/ui/cocoa/share_menu/share_menu_controller.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698