diff options
author | avenjamin <avenjamin@gmail.com> | 2010-03-13 20:51:07 +0000 |
---|---|---|
committer | avenjamin <avenjamin@gmail.com> | 2010-03-13 20:51:07 +0000 |
commit | aff548a80a7d8eacdb836eea70b3e9af14658fdb (patch) | |
tree | 44d60ff91863ebf33fd18f1b1938394847cec088 /Source | |
parent | da87ee2564f73d7f578ffb08e5d03073ce49d694 (diff) | |
download | sequelpro-aff548a80a7d8eacdb836eea70b3e9af14658fdb.tar.gz sequelpro-aff548a80a7d8eacdb836eea70b3e9af14658fdb.tar.bz2 sequelpro-aff548a80a7d8eacdb836eea70b3e9af14658fdb.zip |
- Add toolbar item for Triggers interface
- Add table triggers toolbar icon
Diffstat (limited to 'Source')
-rw-r--r-- | Source/TableDocument.m | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/Source/TableDocument.m b/Source/TableDocument.m index 24636bf3..792e54bc 100644 --- a/Source/TableDocument.m +++ b/Source/TableDocument.m @@ -3390,6 +3390,16 @@ [toolbarItem setTarget:self]; [toolbarItem setAction:@selector(viewRelations:)]; + } else if ([itemIdentifier isEqualToString:SPMainToolbarTableTriggers]) { + [toolbarItem setLabel:NSLocalizedString(@"Triggers", @"toolbar item label for switching to the Table Triggers tab")]; + [toolbarItem setPaletteLabel:NSLocalizedString(@"Table Triggers", @"toolbar item label for switching to the Table Triggers tab")]; + //set up tooltip and image + [toolbarItem setToolTip:NSLocalizedString(@"Switch to the Table Triggers tab", @"tooltip for toolbar item for switching to the Table Triggers tab")]; + [toolbarItem setImage:[NSImage imageNamed:@"toolbar-switch-to-table-triggers"]]; + //set up the target action + [toolbarItem setTarget:self]; + [toolbarItem setAction:@selector(viewTriggers:)]; + } else if ([itemIdentifier isEqualToString:SPMainToolbarUserManager]) { [toolbarItem setLabel:NSLocalizedString(@"Users", @"toolbar item label for switching to the User Manager tab")]; [toolbarItem setPaletteLabel:NSLocalizedString(@"Users", @"toolbar item label for switching to the User Manager tab")]; @@ -3399,6 +3409,7 @@ //set up the target action [toolbarItem setTarget:self]; [toolbarItem setAction:@selector(showUserManager:)]; + } else { //itemIdentifier refered to a toolbar item that is not provided or supported by us or cocoa toolbarItem = nil; @@ -3422,6 +3433,7 @@ SPMainToolbarCustomQuery, SPMainToolbarTableInfo, SPMainToolbarTableRelations, + SPMainToolbarTableTriggers, SPMainToolbarUserManager, NSToolbarCustomizeToolbarItemIdentifier, NSToolbarFlexibleSpaceItemIdentifier, @@ -3460,6 +3472,7 @@ SPMainToolbarCustomQuery, SPMainToolbarTableInfo, SPMainToolbarTableRelations, + SPMainToolbarTableTriggers, nil]; } |