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

Side by Side Diff: chrome/browser/cocoa/cookies_window_controller.h

Issue 546102: [Mac] Fix a crash in the cookies manager that was caused by an invalid selection. (Closed)
Patch Set: do'h Created 10 years, 11 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 | « chrome/app/nibs/Cookies.xib ('k') | chrome/browser/cocoa/cookies_window_controller.mm » ('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 (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 #import <Cocoa/Cocoa.h> 5 #import <Cocoa/Cocoa.h>
6 6
7 #include "app/tree_model.h" 7 #include "app/tree_model.h"
8 #include "base/cocoa_protocols_mac.h" 8 #include "base/cocoa_protocols_mac.h"
9 #include "base/scoped_nsobject.h" 9 #include "base/scoped_nsobject.h"
10 #include "base/scoped_ptr.h" 10 #include "base/scoped_ptr.h"
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 // Platform-independent model and C++/Obj-C bridge components. 74 // Platform-independent model and C++/Obj-C bridge components.
75 scoped_ptr<CookiesTreeModel> treeModel_; 75 scoped_ptr<CookiesTreeModel> treeModel_;
76 scoped_ptr<CookiesTreeModelObserverBridge> modelObserver_; 76 scoped_ptr<CookiesTreeModelObserverBridge> modelObserver_;
77 77
78 // Cached array of icons. 78 // Cached array of icons.
79 scoped_nsobject<NSMutableArray> icons_; 79 scoped_nsobject<NSMutableArray> icons_;
80 80
81 // Our Cocoa copy of the model. 81 // Our Cocoa copy of the model.
82 scoped_nsobject<CocoaCookieTreeNode> cocoaTreeModel_; 82 scoped_nsobject<CocoaCookieTreeNode> cocoaTreeModel_;
83 83
84 // A flag indicating whether or not the "Remove" button should be enabled.
85 BOOL removeButtonEnabled_;
86
84 IBOutlet NSTreeController* treeController_; 87 IBOutlet NSTreeController* treeController_;
85 88
86 Profile* profile_; // weak 89 Profile* profile_; // weak
87 } 90 }
91 @property (assign, nonatomic) BOOL removeButtonEnabled;
88 @property (readonly, nonatomic) NSTreeController* treeController; 92 @property (readonly, nonatomic) NSTreeController* treeController;
89 93
90 // Designated initializer. Profile cannot be NULL. 94 // Designated initializer. Profile cannot be NULL.
91 - (id)initWithProfile:(Profile*)profile; 95 - (id)initWithProfile:(Profile*)profile;
92 96
93 // Shows the cookies window as a modal sheet attached to |window|. 97 // Shows the cookies window as a modal sheet attached to |window|.
94 - (void)attachSheetTo:(NSWindow*)window; 98 - (void)attachSheetTo:(NSWindow*)window;
95 99
96 // Delete cookie actions. 100 // Delete cookie actions.
97 - (IBAction)deleteCookie:(id)sender; 101 - (IBAction)deleteCookie:(id)sender;
(...skipping 10 matching lines...) Expand all
108 - (CookiesTreeModel*)treeModel; 112 - (CookiesTreeModel*)treeModel;
109 113
110 @end 114 @end
111 115
112 @interface CookiesWindowController (UnitTesting) 116 @interface CookiesWindowController (UnitTesting)
113 - (void)clearBrowsingDataNotification:(NSNotification*)notif; 117 - (void)clearBrowsingDataNotification:(NSNotification*)notif;
114 - (CookiesTreeModelObserverBridge*)modelObserver; 118 - (CookiesTreeModelObserverBridge*)modelObserver;
115 - (NSArray*)icons; 119 - (NSArray*)icons;
116 - (void)loadTreeModelFromProfile; 120 - (void)loadTreeModelFromProfile;
117 @end 121 @end
OLDNEW
« no previous file with comments | « chrome/app/nibs/Cookies.xib ('k') | chrome/browser/cocoa/cookies_window_controller.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698