blob: 23e76e096a80fb13cd98ed278a2cde387d5a1dbd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
// Copyright (c) 2009 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_COCOA_ABOUT_WINDOW_CONTROLLER_H_
#define CHROME_BROWSER_COCOA_ABOUT_WINDOW_CONTROLLER_H_
#import <AppKit/AppKit.h>
@class BackgroundTileView;
class Profile;
// kUserClosedAboutNotification is the name of the notification posted when
// the About window is closed.
extern const NSString* const kUserClosedAboutNotification;
// A window controller that handles the About box.
@interface AboutWindowController : NSWindowController {
@private
IBOutlet NSTextField* version_;
IBOutlet BackgroundTileView* backgroundView_;
IBOutlet NSImageView* logoView_;
IBOutlet NSView* legalBlock_;
IBOutlet NSTextView* legalText_;
IBOutlet NSView* updateBlock_; // Holds everything related to updates
IBOutlet NSProgressIndicator* spinner_;
IBOutlet NSImageView* updateStatusIndicator_;
IBOutlet NSTextField* updateText_;
IBOutlet NSButton* updateNowButton_;
BOOL updateTriggered_; // Has an update ever been triggered?
Profile* profile_; // Weak, probably the default profile.
}
// Initialize the controller with the given profile, but does not show it.
// Callers still need to call showWindow: to put it on screen.
- (id)initWithProfile:(Profile*)profile;
// Trigger an update right now, as initiated by a button.
- (IBAction)updateNow:(id)sender;
@end // @interface AboutWindowController
@interface AboutWindowController(JustForTesting)
- (NSTextView*)legalText;
- (NSButton*)updateButton;
- (NSTextField*)updateText;
// Returns an NSAttributedString that contains locale-specific legal text.
+ (NSAttributedString*)legalTextBlock;
@end // @interface AboutWindowController(JustForTesting)
#endif // CHROME_BROWSER_COCOA_ABOUT_WINDOW_CONTROLLER_H_
|