diff options
Diffstat (limited to 'cocoa/BrowserWindowController.m')
-rw-r--r-- | cocoa/BrowserWindowController.m | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/cocoa/BrowserWindowController.m b/cocoa/BrowserWindowController.m index 9fa502429..343bd42e6 100644 --- a/cocoa/BrowserWindowController.m +++ b/cocoa/BrowserWindowController.m @@ -42,6 +42,8 @@ @synthesize urlField; @synthesize navigationControl; @synthesize historyButton; +@synthesize historyBackMenu; +@synthesize historyForwardMenu; @synthesize activeBrowser; @synthesize activeBrowserController; @@ -83,6 +85,9 @@ [self bind: @"canGoForward" toObject: activeBrowserController withKeyPath: @"selection.canGoForward" options: nil]; + + [navigationControl setMenu: historyBackMenu forSegment: 0]; + [navigationControl setMenu: historyForwardMenu forSegment: 1]; } - (void) addTab: (BrowserViewController *)browser; @@ -184,6 +189,15 @@ [(NetSurfApp *)NSApp setFrontTab: [[tabView selectedTabViewItem] identifier]]; } +- (void)menuNeedsUpdate:(NSMenu *)menu +{ + if (menu == historyBackMenu) { + [activeBrowser buildBackMenu: menu]; + } else if (menu == historyForwardMenu) { + [activeBrowser buildForwardMenu: menu]; + } +} + #pragma mark - #pragma mark Tab bar delegate |