Browse files

Added additional ways to close window: Command-W and menu item

  • Loading branch information...
1 parent bd86385 commit ac4a24ebd711a207fd0bef1ece68a78d4cbae6c5 @mmattozzi committed Sep 16, 2012
Showing with 59 additions and 3 deletions.
  1. +1 −0 CocoaRestClientAppDelegate.h
  2. +4 −0 CocoaRestClientAppDelegate.m
  3. +53 −3 English.lproj/MainMenu.xib
  4. +1 −0 ReleaseNotes/1.3.4.html
View
1 CocoaRestClientAppDelegate.h
@@ -166,6 +166,7 @@ extern NSString* const RESPONSE_TIMEOUT;
- (IBAction) minusParamsRow:(id)sender;
- (IBAction) contentTypeMenuItemSelected:(id)sender;
- (IBAction) handleOpenWindow:(id)sender;
+- (IBAction) handleCloseWindow:(id)sender;
- (BOOL)validateMenuItem:(NSMenuItem *)item;
- (IBAction) helpInfo:(id)sender;
- (IBAction) licenseInfo:(id)sender;
View
4 CocoaRestClientAppDelegate.m
@@ -1076,6 +1076,10 @@ - (IBAction) handleOpenWindow:(id)sender {
[window makeKeyAndOrderFront:self];
}
+- (IBAction) handleCloseWindow:(id)sender {
+ [window close];
+}
+
// Including this to disable Open Window menu item when window is already open
- (BOOL)validateMenuItem:(NSMenuItem *)item
{
View
56 English.lproj/MainMenu.xib
@@ -231,6 +231,25 @@
<reference key="NSMixedImage" ref="502551668"/>
<int key="NSTag">150</int>
</object>
+ <object class="NSMenuItem" id="254033814">
+ <reference key="NSMenu" ref="365660756"/>
+ <string key="NSTitle">Close Window</string>
+ <string key="NSKeyEquiv">w</string>
+ <int key="NSKeyEquivModMask">1048576</int>
+ <int key="NSMnemonicLoc">2147483647</int>
+ <reference key="NSOnImage" ref="35465992"/>
+ <reference key="NSMixedImage" ref="502551668"/>
+ </object>
+ <object class="NSMenuItem" id="1010479660">
+ <reference key="NSMenu" ref="365660756"/>
+ <bool key="NSIsDisabled">YES</bool>
+ <bool key="NSIsSeparator">YES</bool>
+ <string key="NSTitle"/>
+ <string key="NSKeyEquiv"/>
+ <int key="NSMnemonicLoc">2147483647</int>
+ <reference key="NSOnImage" ref="35465992"/>
+ <reference key="NSMixedImage" ref="502551668"/>
+ </object>
<object class="NSMenuItem" id="976512172">
<reference key="NSMenu" ref="365660756"/>
<string key="NSTitle">Reload Request</string>
@@ -1449,7 +1468,7 @@ AAEAAQAAAT0AAwAAAAEAAgAAAVIAAwAAAAEAAQAAAVMAAwAAAAIAAQABAAAAAA</bytes>
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSTableColumn" id="600659076">
<string key="NSIdentifier">key</string>
- <double key="NSWidth">541</double>
+ <double key="NSWidth">538</double>
<double key="NSMinWidth">40</double>
<double key="NSMaxWidth">1000</double>
<object class="NSTableHeaderCell" key="NSHeaderCell">
@@ -1489,7 +1508,7 @@ AAEAAQAAAT0AAwAAAAEAAgAAAVIAAwAAAAEAAQAAAVMAAwAAAAIAAQABAAAAAA</bytes>
</object>
<object class="NSTableColumn" id="718401187">
<string key="NSIdentifier">value</string>
- <double key="NSWidth">526</double>
+ <double key="NSWidth">529</double>
<double key="NSMinWidth">40</double>
<double key="NSMaxWidth">1000</double>
<object class="NSTableHeaderCell" key="NSHeaderCell">
@@ -3906,6 +3925,14 @@ AAEAAQAAAT0AAwAAAAEAAgAAAVIAAwAAAAEAAQAAAVMAAwAAAAIAAQABAAAAAA</bytes>
<int key="connectionID">1019</int>
</object>
<object class="IBConnectionRecord">
+ <object class="IBActionConnection" key="connection">
+ <string key="label">handleCloseWindow:</string>
+ <reference key="source" ref="976324537"/>
+ <reference key="destination" ref="254033814"/>
+ </object>
+ <int key="connectionID">1022</int>
+ </object>
+ <object class="IBConnectionRecord">
<object class="IBOutletConnection" key="connection">
<string key="label">dataSource</string>
<reference key="source" ref="887227541"/>
@@ -4641,6 +4668,8 @@ AAEAAQAAAT0AAwAAAAEAAgAAAVIAAwAAAAEAAQAAAVMAAwAAAAIAAQABAAAAAA</bytes>
<reference ref="851889150"/>
<reference ref="856384542"/>
<reference ref="139677461"/>
+ <reference ref="254033814"/>
+ <reference ref="1010479660"/>
</object>
<reference key="parent" ref="699702702"/>
</object>
@@ -5748,6 +5777,16 @@ AAEAAQAAAT0AAwAAAAEAAgAAAVIAAwAAAAEAAQAAAVMAAwAAAAIAAQABAAAAAA</bytes>
<reference key="object" ref="139677461"/>
<reference key="parent" ref="365660756"/>
</object>
+ <object class="IBObjectRecord">
+ <int key="objectID">1020</int>
+ <reference key="object" ref="254033814"/>
+ <reference key="parent" ref="365660756"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">1021</int>
+ <reference key="object" ref="1010479660"/>
+ <reference key="parent" ref="365660756"/>
+ </object>
</object>
</object>
<object class="NSMutableDictionary" key="flattenedProperties">
@@ -5766,6 +5805,8 @@ AAEAAQAAAT0AAwAAAAEAAgAAAVIAAwAAAAEAAQAAAVMAAwAAAAIAAQABAAAAAA</bytes>
<string>1012.IBPluginDependency</string>
<string>1013.IBPluginDependency</string>
<string>1018.IBPluginDependency</string>
+ <string>1020.IBPluginDependency</string>
+ <string>1021.IBPluginDependency</string>
<string>129.IBPluginDependency</string>
<string>130.IBPluginDependency</string>
<string>131.IBPluginDependency</string>
@@ -6026,6 +6067,8 @@ AAEAAQAAAT0AAwAAAAEAAgAAAVIAAwAAAAEAAQAAAVMAAwAAAAIAAQABAAAAAA</bytes>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{253, 261}, {1004, 650}}</string>
<integer value="1"/>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
@@ -6259,7 +6302,7 @@ AAEAAQAAAT0AAwAAAAEAAgAAAVIAAwAAAAEAAQAAAVMAAwAAAAIAAQABAAAAAA</bytes>
<reference key="dict.values" ref="0"/>
</object>
<nil key="sourceID"/>
- <int key="maxID">1019</int>
+ <int key="maxID">1022</int>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes">
<object class="NSMutableArray" key="referencedPartialClassDescriptions">
@@ -6299,6 +6342,7 @@ AAEAAQAAAT0AAwAAAAEAAgAAAVIAAwAAAAEAAQAAAVMAAwAAAAIAAQABAAAAAA</bytes>
<string>doubleClickedParamsRow:</string>
<string>exportRequests:</string>
<string>exportResponse:</string>
+ <string>handleCloseWindow:</string>
<string>handleOpenWindow:</string>
<string>helpInfo:</string>
<string>importRequests:</string>
@@ -6362,6 +6406,7 @@ AAEAAQAAAT0AAwAAAAEAAgAAAVIAAwAAAAEAAQAAAVMAAwAAAAIAAQABAAAAAA</bytes>
<string>id</string>
<string>id</string>
<string>id</string>
+ <string>id</string>
</object>
</object>
<object class="NSMutableDictionary" key="actionInfosByName">
@@ -6380,6 +6425,7 @@ AAEAAQAAAT0AAwAAAAEAAgAAAVIAAwAAAAEAAQAAAVMAAwAAAAIAAQABAAAAAA</bytes>
<string>doubleClickedParamsRow:</string>
<string>exportRequests:</string>
<string>exportResponse:</string>
+ <string>handleCloseWindow:</string>
<string>handleOpenWindow:</string>
<string>helpInfo:</string>
<string>importRequests:</string>
@@ -6456,6 +6502,10 @@ AAEAAQAAAT0AAwAAAAEAAgAAAVIAAwAAAAEAAQAAAVMAAwAAAAIAAQABAAAAAA</bytes>
<string key="candidateClassName">id</string>
</object>
<object class="IBActionInfo">
+ <string key="name">handleCloseWindow:</string>
+ <string key="candidateClassName">id</string>
+ </object>
+ <object class="IBActionInfo">
<string key="name">handleOpenWindow:</string>
<string key="candidateClassName">id</string>
</object>
View
1 ReleaseNotes/1.3.4.html
@@ -1,6 +1,7 @@
New in 1.3.4:
* Pick more appropriate syntax highlighting based on certain known Content-Types
* Respect the HTTP Method on redirected requests
+* Menu item and Command-W added for closing window
New in 1.3.3:
* Added syntax highlighting to raw requests and responses (can be enabled or disabled via menu option)

0 comments on commit ac4a24e

Please sign in to comment.