aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Interfaces/English.lproj/DBView.xib211
-rw-r--r--Source/TableSource.m23
2 files changed, 173 insertions, 61 deletions
diff --git a/Interfaces/English.lproj/DBView.xib b/Interfaces/English.lproj/DBView.xib
index 5e4b146b..a550f7c8 100644
--- a/Interfaces/English.lproj/DBView.xib
+++ b/Interfaces/English.lproj/DBView.xib
@@ -8,8 +8,8 @@
<string key="IBDocument.HIToolboxVersion">353.00</string>
<object class="NSMutableArray" key="IBDocument.EditedObjectIDs">
<bool key="EncodedWithXMLCoder">YES</bool>
- <integer value="557"/>
- <integer value="5322"/>
+ <integer value="6220"/>
+ <integer value="672"/>
</object>
<object class="NSArray" key="IBDocument.PluginDependencies">
<bool key="EncodedWithXMLCoder">YES</bool>
@@ -92,7 +92,6 @@
<int key="NSvFlags">4352</int>
<string key="NSFrameSize">{212, 381}</string>
<reference key="NSSuperview" ref="73685676"/>
- <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="_NSCornerView" key="NSCornerView">
<nil key="NSNextResponder"/>
@@ -189,7 +188,6 @@
</object>
<string key="NSFrameSize">{212, 381}</string>
<reference key="NSSuperview" ref="233472824"/>
- <reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="251040077"/>
<reference key="NSDocView" ref="251040077"/>
<object class="NSColor" key="NSBGColor" id="1024678221">
@@ -205,7 +203,6 @@
<int key="NSvFlags">-2147483392</int>
<string key="NSFrame">{{175, 1}, {15, 481}}</string>
<reference key="NSSuperview" ref="233472824"/>
- <reference key="NSWindow"/>
<reference key="NSTarget" ref="233472824"/>
<string key="NSAction">_doScroller:</string>
<double key="NSPercent">9.979253e-01</double>
@@ -215,7 +212,6 @@
<int key="NSvFlags">256</int>
<string key="NSFrame">{{-100, -100}, {141, 11}}</string>
<reference key="NSSuperview" ref="233472824"/>
- <reference key="NSWindow"/>
<int key="NSsFlags">257</int>
<reference key="NSTarget" ref="233472824"/>
<string key="NSAction">_doScroller:</string>
@@ -224,7 +220,6 @@
</object>
<string key="NSFrameSize">{212, 381}</string>
<reference key="NSSuperview" ref="355288374"/>
- <reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="73685676"/>
<int key="NSsFlags">528</int>
<reference key="NSVScroller" ref="693168867"/>
@@ -235,12 +230,10 @@
</object>
<string key="NSFrameSize">{212, 381}</string>
<reference key="NSSuperview" ref="131633443"/>
- <reference key="NSWindow"/>
</object>
</object>
<string key="NSFrameSize">{212, 381}</string>
<reference key="NSSuperview" ref="298095498"/>
- <reference key="NSWindow"/>
<string key="NSClassName">NSView</string>
</object>
<object class="BWCustomView" id="192579410">
@@ -263,7 +256,6 @@
<int key="NSvFlags">4352</int>
<string key="NSFrameSize">{212, 145}</string>
<reference key="NSSuperview" ref="685057119"/>
- <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="_NSCornerView" key="NSCornerView">
<nil key="NSNextResponder"/>
@@ -327,7 +319,6 @@
</object>
<string key="NSFrameSize">{212, 145}</string>
<reference key="NSSuperview" ref="298226231"/>
- <reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="347093764"/>
<reference key="NSDocView" ref="347093764"/>
<reference key="NSBGColor" ref="1024678221"/>
@@ -338,7 +329,6 @@
<int key="NSvFlags">-2147483392</int>
<string key="NSFrame">{{-100, -100}, {15, 20}}</string>
<reference key="NSSuperview" ref="298226231"/>
- <reference key="NSWindow"/>
<reference key="NSTarget" ref="298226231"/>
<string key="NSAction">_doScroller:</string>
<double key="NSPercent">9.473684e-01</double>
@@ -348,7 +338,6 @@
<int key="NSvFlags">256</int>
<string key="NSFrame">{{-100, -100}, {141, 11}}</string>
<reference key="NSSuperview" ref="298226231"/>
- <reference key="NSWindow"/>
<int key="NSsFlags">257</int>
<reference key="NSTarget" ref="298226231"/>
<string key="NSAction">_doScroller:</string>
@@ -357,7 +346,6 @@
</object>
<string key="NSFrameSize">{212, 145}</string>
<reference key="NSSuperview" ref="192579410"/>
- <reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="685057119"/>
<int key="NSsFlags">512</int>
<reference key="NSVScroller" ref="245346414"/>
@@ -368,13 +356,11 @@
</object>
<string key="NSFrame">{{0, 382}, {212, 145}}</string>
<reference key="NSSuperview" ref="298095498"/>
- <reference key="NSWindow"/>
<string key="NSClassName">NSView</string>
</object>
</object>
<string key="NSFrame">{{0, 23}, {212, 527}}</string>
<reference key="NSSuperview" ref="372294785"/>
- <reference key="NSWindow"/>
<int key="NSDividerStyle">2</int>
<reference key="BWSVColor" ref="304829493"/>
<bool key="BWSVColorIsEnabled">NO</bool>
@@ -425,7 +411,6 @@
<int key="NSvFlags">268</int>
<string key="NSFrame">{{-1, -1}, {32, 24}}</string>
<reference key="NSSuperview" ref="28219887"/>
- <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="BWAnchoredButtonCell" key="NSCell" id="283448047">
<int key="NSCellFlags">67239424</int>
@@ -450,7 +435,6 @@
<int key="NSvFlags">268</int>
<string key="NSFrame">{{30, -1}, {32, 24}}</string>
<reference key="NSSuperview" ref="28219887"/>
- <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="BWAnchoredPopUpButtonCell" key="NSCell" id="321871356">
<int key="NSCellFlags">71433792</int>
@@ -560,7 +544,6 @@
<int key="NSvFlags">268</int>
<string key="NSFrame">{{61, -1}, {32, 24}}</string>
<reference key="NSSuperview" ref="28219887"/>
- <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="BWAnchoredButtonCell" key="NSCell" id="227511715">
<int key="NSCellFlags">67239424</int>
@@ -585,7 +568,6 @@
<int key="NSvFlags">268</int>
<string key="NSFrame">{{92, -1}, {32, 24}}</string>
<reference key="NSSuperview" ref="28219887"/>
- <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="BWAnchoredButtonCell" key="NSCell" id="708016222">
<int key="NSCellFlags">-2080244224</int>
@@ -612,7 +594,6 @@
</object>
<string key="NSFrameSize">{212, 23}</string>
<reference key="NSSuperview" ref="372294785"/>
- <reference key="NSWindow"/>
<bool key="BWABBIsResizable">YES</bool>
<bool key="BWABBIsAtBottom">YES</bool>
<bool key="BWABBHandleIsRightAligned">NO</bool>
@@ -621,7 +602,6 @@
</object>
<string key="NSFrameSize">{212, 550}</string>
<reference key="NSSuperview" ref="937377983"/>
- <reference key="NSWindow"/>
<string key="NSClassName">NSView</string>
</object>
<object class="NSCustomView" id="604818293">
@@ -634,13 +614,12 @@
<int key="NSvFlags">274</int>
<string key="NSFrame">{{-7, -10}, {735, 564}}</string>
<reference key="NSSuperview" ref="604818293"/>
- <reference key="NSWindow"/>
<object class="NSMutableArray" key="NSTabViewItems">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSTabViewItem" id="831053945">
<string key="NSIdentifier">source</string>
<object class="NSView" key="NSView" id="461236772">
- <nil key="NSNextResponder"/>
+ <reference key="NSNextResponder" ref="714795046"/>
<int key="NSvFlags">256</int>
<object class="NSMutableArray" key="NSSubviews">
<bool key="EncodedWithXMLCoder">YES</bool>
@@ -1954,6 +1933,7 @@
</object>
</object>
<string key="NSFrame">{{10, 7}, {700, 544}}</string>
+ <reference key="NSSuperview" ref="714795046"/>
</object>
<string key="NSLabel">Structure</string>
<reference key="NSColor" ref="62854682"/>
@@ -3999,7 +3979,7 @@
<object class="NSTabViewItem" id="986490149">
<string key="NSIdentifier">relations</string>
<object class="NSView" key="NSView" id="49633996">
- <reference key="NSNextResponder" ref="714795046"/>
+ <nil key="NSNextResponder"/>
<int key="NSvFlags">256</int>
<object class="NSMutableArray" key="NSSubviews">
<bool key="EncodedWithXMLCoder">YES</bool>
@@ -4018,14 +3998,12 @@
<int key="NSvFlags">4352</int>
<string key="NSFrameSize">{688, 454}</string>
<reference key="NSSuperview" ref="705580858"/>
- <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="NSTableHeaderView" key="NSHeaderView" id="370758200">
<reference key="NSNextResponder" ref="996985254"/>
<int key="NSvFlags">256</int>
<string key="NSFrameSize">{688, 17}</string>
<reference key="NSSuperview" ref="996985254"/>
- <reference key="NSWindow"/>
<reference key="NSTableView" ref="952375340"/>
</object>
<object class="_NSCornerView" key="NSCornerView" id="793765259">
@@ -4033,7 +4011,6 @@
<int key="NSvFlags">-2147483392</int>
<string key="NSFrame">{{-26, 0}, {16, 17}}</string>
<reference key="NSSuperview" ref="717203719"/>
- <reference key="NSWindow"/>
</object>
<object class="NSMutableArray" key="NSTableColumns">
<bool key="EncodedWithXMLCoder">YES</bool>
@@ -4217,7 +4194,6 @@
</object>
<string key="NSFrame">{{1, 17}, {688, 454}}</string>
<reference key="NSSuperview" ref="717203719"/>
- <reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="952375340"/>
<reference key="NSDocView" ref="952375340"/>
<reference key="NSBGColor" ref="1024678221"/>
@@ -4228,7 +4204,6 @@
<int key="NSvFlags">-2147483392</int>
<string key="NSFrame">{{674, 17}, {15, 453}}</string>
<reference key="NSSuperview" ref="717203719"/>
- <reference key="NSWindow"/>
<reference key="NSTarget" ref="717203719"/>
<string key="NSAction">_doScroller:</string>
<double key="NSPercent">9.679487e-01</double>
@@ -4238,7 +4213,6 @@
<int key="NSvFlags">-2147483392</int>
<string key="NSFrame">{{1, 470}, {688, 15}}</string>
<reference key="NSSuperview" ref="717203719"/>
- <reference key="NSWindow"/>
<int key="NSsFlags">1</int>
<reference key="NSTarget" ref="717203719"/>
<string key="NSAction">_doScroller:</string>
@@ -4253,7 +4227,6 @@
</object>
<string key="NSFrame">{{1, 0}, {688, 17}}</string>
<reference key="NSSuperview" ref="717203719"/>
- <reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="370758200"/>
<reference key="NSDocView" ref="370758200"/>
<reference key="NSBGColor" ref="1024678221"/>
@@ -4263,7 +4236,6 @@
</object>
<string key="NSFrame">{{6, 32}, {690, 472}}</string>
<reference key="NSSuperview" ref="49633996"/>
- <reference key="NSWindow"/>
<reference key="NSNextKeyView" ref="705580858"/>
<int key="NSsFlags">562</int>
<reference key="NSVScroller" ref="429193901"/>
@@ -4278,7 +4250,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{6, 9}, {32, 25}}</string>
<reference key="NSSuperview" ref="49633996"/>
- <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="NSButtonCell" key="NSCell" id="796363844">
<int key="NSCellFlags">-1543373312</int>
@@ -4300,7 +4271,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{68, 9}, {32, 25}}</string>
<reference key="NSSuperview" ref="49633996"/>
- <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="NSButtonCell" key="NSCell" id="815097407">
<int key="NSCellFlags">-2080244224</int>
@@ -4322,7 +4292,6 @@
<int key="NSvFlags">292</int>
<string key="NSFrame">{{37, 9}, {32, 25}}</string>
<reference key="NSSuperview" ref="49633996"/>
- <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="NSButtonCell" key="NSCell" id="693201961">
<int key="NSCellFlags">-1543373312</int>
@@ -4356,7 +4325,6 @@
</object>
<string key="NSFrame">{{100, 10}, {596, 23}}</string>
<reference key="NSSuperview" ref="49633996"/>
- <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="NSImageCell" key="NSCell" id="889065570">
<int key="NSCellFlags">130560</int>
@@ -4374,7 +4342,6 @@
<int key="NSvFlags">268</int>
<string key="NSFrame">{{14, 515}, {347, 14}}</string>
<reference key="NSSuperview" ref="49633996"/>
- <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="NSTextFieldCell" key="NSCell" id="538829847">
<int key="NSCellFlags">68288064</int>
@@ -4388,41 +4355,36 @@
</object>
</object>
<string key="NSFrame">{{10, 7}, {700, 544}}</string>
- <reference key="NSSuperview" ref="714795046"/>
- <reference key="NSWindow"/>
</object>
<string key="NSLabel">Relations</string>
<reference key="NSColor" ref="62854682"/>
<reference key="NSTabView" ref="714795046"/>
</object>
</object>
- <reference key="NSSelectedTabViewItem" ref="986490149"/>
+ <reference key="NSSelectedTabViewItem" ref="831053945"/>
<reference key="NSFont" ref="26"/>
<int key="NSTvFlags">134217731</int>
<bool key="NSAllowTruncatedLabels">YES</bool>
<bool key="NSDrawsBackground">YES</bool>
<object class="NSMutableArray" key="NSSubviews">
<bool key="EncodedWithXMLCoder">YES</bool>
- <reference ref="49633996"/>
+ <reference ref="461236772"/>
</object>
</object>
</object>
<string key="NSFrame">{{221, 0}, {723, 550}}</string>
<reference key="NSSuperview" ref="937377983"/>
- <reference key="NSWindow"/>
<string key="NSClassName">NSView</string>
</object>
</object>
<string key="NSFrameSize">{944, 550}</string>
<reference key="NSSuperview" ref="579726586"/>
- <reference key="NSWindow"/>
<bool key="NSIsVertical">YES</bool>
<string key="NSAutosaveName">DBViewSplitter</string>
</object>
</object>
<string key="NSFrameSize">{944, 550}</string>
<reference key="NSSuperview"/>
- <reference key="NSWindow"/>
</object>
<string key="NSScreenRect">{{0, 0}, {1920, 1178}}</string>
<string key="NSMinSize">{780, 502}</string>
@@ -5293,7 +5255,7 @@
<string key="NSWindowContentMaxSize">{292, 112}</string>
<string key="NSWindowContentMinSize">{292, 112}</string>
<object class="NSView" key="NSWindowView" id="70075497">
- <reference key="NSNextResponder"/>
+ <nil key="NSNextResponder"/>
<int key="NSvFlags">256</int>
<object class="NSMutableArray" key="NSSubviews">
<bool key="EncodedWithXMLCoder">YES</bool>
@@ -5719,7 +5681,6 @@
</object>
</object>
<string key="NSFrameSize">{292, 112}</string>
- <reference key="NSSuperview"/>
</object>
<string key="NSScreenRect">{{0, 0}, {1440, 878}}</string>
<string key="NSMinSize">{292, 134}</string>
@@ -5738,7 +5699,7 @@
<string key="NSWindowContentMaxSize">{600, 142}</string>
<string key="NSWindowContentMinSize">{269, 142}</string>
<object class="NSView" key="NSWindowView" id="846512394">
- <reference key="NSNextResponder"/>
+ <nil key="NSNextResponder"/>
<int key="NSvFlags">256</int>
<object class="NSMutableArray" key="NSSubviews">
<bool key="EncodedWithXMLCoder">YES</bool>
@@ -6211,7 +6172,6 @@
</object>
</object>
<string key="NSFrameSize">{269, 142}</string>
- <reference key="NSSuperview"/>
</object>
<string key="NSScreenRect">{{0, 0}, {1680, 1028}}</string>
<string key="NSMinSize">{269, 164}</string>
@@ -12689,6 +12649,42 @@ IGRvIHlvdSB3YW50IHRvIGFkZCBmb3IgdGhpcyBmaWVsZD8</string>
</object>
</object>
</object>
+ <object class="NSMenu" id="351243688">
+ <string key="NSTitle"/>
+ <object class="NSMutableArray" key="NSMenuItems">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <object class="NSMenuItem" id="505982688">
+ <reference key="NSMenu" ref="351243688"/>
+ <string key="NSTitle">Delete Index</string>
+ <string key="NSKeyEquiv"/>
+ <int key="NSMnemonicLoc">2147483647</int>
+ <reference key="NSOnImage" ref="450876295"/>
+ <reference key="NSMixedImage" ref="414351669"/>
+ </object>
+ </object>
+ </object>
+ <object class="NSMenu" id="752657505">
+ <string key="NSTitle"/>
+ <object class="NSMutableArray" key="NSMenuItems">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <object class="NSMenuItem" id="282262200">
+ <reference key="NSMenu" ref="752657505"/>
+ <string key="NSTitle">Delete Field</string>
+ <string key="NSKeyEquiv"/>
+ <int key="NSMnemonicLoc">2147483647</int>
+ <reference key="NSOnImage" ref="450876295"/>
+ <reference key="NSMixedImage" ref="414351669"/>
+ </object>
+ <object class="NSMenuItem" id="338933187">
+ <reference key="NSMenu" ref="752657505"/>
+ <string key="NSTitle">Duplicate Field</string>
+ <string key="NSKeyEquiv"/>
+ <int key="NSMnemonicLoc">2147483647</int>
+ <reference key="NSOnImage" ref="450876295"/>
+ <reference key="NSMixedImage" ref="414351669"/>
+ </object>
+ </object>
+ </object>
</object>
<object class="IBObjectContainer" key="IBDocument.Objects">
<object class="NSMutableArray" key="connectionRecords">
@@ -16513,6 +16509,54 @@ IGRvIHlvdSB3YW50IHRvIGFkZCBmb3IgdGhpcyBmaWVsZD8</string>
</object>
<int key="connectionID">6209</int>
</object>
+ <object class="IBConnectionRecord">
+ <object class="IBActionConnection" key="connection">
+ <string key="label">removeField:</string>
+ <reference key="source" ref="103234030"/>
+ <reference key="destination" ref="282262200"/>
+ </object>
+ <int key="connectionID">6215</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBActionConnection" key="connection">
+ <string key="label">copyField:</string>
+ <reference key="source" ref="103234030"/>
+ <reference key="destination" ref="338933187"/>
+ </object>
+ <int key="connectionID">6216</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBOutletConnection" key="connection">
+ <string key="label">menu</string>
+ <reference key="source" ref="22340145"/>
+ <reference key="destination" ref="752657505"/>
+ </object>
+ <int key="connectionID">6217</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBOutletConnection" key="connection">
+ <string key="label">menu</string>
+ <reference key="source" ref="715508012"/>
+ <reference key="destination" ref="752657505"/>
+ </object>
+ <int key="connectionID">6218</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBOutletConnection" key="connection">
+ <string key="label">menu</string>
+ <reference key="source" ref="584834515"/>
+ <reference key="destination" ref="351243688"/>
+ </object>
+ <int key="connectionID">6223</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBActionConnection" key="connection">
+ <string key="label">removeIndex:</string>
+ <reference key="source" ref="103234030"/>
+ <reference key="destination" ref="505982688"/>
+ </object>
+ <int key="connectionID">6224</int>
+ </object>
</object>
<object class="IBMutableOrderedSet" key="objectRecords">
<object class="NSArray" key="orderedObjects">
@@ -23272,7 +23316,7 @@ IGRvIHlvdSB3YW50IHRvIGFkZCBmb3IgdGhpcyBmaWVsZD8</string>
<reference ref="584064012"/>
</object>
<reference key="parent" ref="1043842561"/>
- <string key="objectName">Context Menu (Table List)</string>
+ <string key="objectName">Table List Menu</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">6182</int>
@@ -23299,6 +23343,42 @@ IGRvIHlvdSB3YW50IHRvIGFkZCBmb3IgdGhpcyBmaWVsZD8</string>
<reference key="object" ref="584064012"/>
<reference key="parent" ref="556141845"/>
</object>
+ <object class="IBObjectRecord">
+ <int key="objectID">6210</int>
+ <reference key="object" ref="752657505"/>
+ <object class="NSMutableArray" key="children">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <reference ref="338933187"/>
+ <reference ref="282262200"/>
+ </object>
+ <reference key="parent" ref="1043842561"/>
+ <string key="objectName">Table Structure Menu</string>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">6211</int>
+ <reference key="object" ref="338933187"/>
+ <reference key="parent" ref="752657505"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">6212</int>
+ <reference key="object" ref="282262200"/>
+ <reference key="parent" ref="752657505"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">6219</int>
+ <reference key="object" ref="351243688"/>
+ <object class="NSMutableArray" key="children">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <reference ref="505982688"/>
+ </object>
+ <reference key="parent" ref="1043842561"/>
+ <string key="objectName">Table Indexes Menu</string>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">6220</int>
+ <reference key="object" ref="505982688"/>
+ <reference key="parent" ref="351243688"/>
+ </object>
</object>
</object>
<object class="NSMutableDictionary" key="flattenedProperties">
@@ -24705,6 +24785,13 @@ IGRvIHlvdSB3YW50IHRvIGFkZCBmb3IgdGhpcyBmaWVsZD8</string>
<string>6185.IBPluginDependency</string>
<string>6186.IBAttributePlaceholdersKey</string>
<string>6186.IBPluginDependency</string>
+ <string>6210.IBEditorWindowLastContentRect</string>
+ <string>6210.IBPluginDependency</string>
+ <string>6211.IBPluginDependency</string>
+ <string>6212.IBPluginDependency</string>
+ <string>6219.IBEditorWindowLastContentRect</string>
+ <string>6219.IBPluginDependency</string>
+ <string>6220.IBPluginDependency</string>
<string>654.IBPluginDependency</string>
<string>654.ImportedFromIB2</string>
<string>655.IBPluginDependency</string>
@@ -25105,11 +25192,6 @@ IGRvIHlvdSB3YW50IHRvIGFkZCBmb3IgdGhpcyBmaWVsZD8</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<object class="NSMutableArray">
<bool key="EncodedWithXMLCoder">YES</bool>
- <object class="IBUserGuide">
- <reference key="view" ref="730602982"/>
- <float key="location">3.670000e+02</float>
- <int key="affinity">0</int>
- </object>
</object>
<reference ref="9"/>
<object class="NSMutableDictionary">
@@ -25863,8 +25945,8 @@ IGRvIHlvdSB3YW50IHRvIGFkZCBmb3IgdGhpcyBmaWVsZD8</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<reference ref="9"/>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
- <string>{{187, 237}, {944, 550}}</string>
- <string>{{187, 237}, {944, 550}}</string>
+ <string>{{235, 270}, {944, 550}}</string>
+ <string>{{235, 270}, {944, 550}}</string>
<reference ref="9"/>
<reference ref="9"/>
<string>{{62, 352}, {845, 504}}</string>
@@ -26313,8 +26395,8 @@ aGUgYWN0aXZlIHNlbGVjdGlvbiAo4oyl4oyYUik</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
- <string>{{456, 426}, {292, 112}}</string>
- <string>{{456, 426}, {292, 112}}</string>
+ <string>{{456, 425}, {292, 112}}</string>
+ <string>{{456, 425}, {292, 112}}</string>
<reference ref="9"/>
<reference ref="9"/>
<reference ref="9"/>
@@ -26569,7 +26651,7 @@ aGUgYWN0aXZlIHNlbGVjdGlvbiAo4oyl4oyYUik</string>
<string>com.brandonwalkin.BWToolkit</string>
<string>com.brandonwalkin.BWToolkit</string>
<string>com.brandonwalkin.BWToolkit</string>
- <string>{{325, 248}, {157, 98}}</string>
+ <string>{{463, 282}, {157, 98}}</string>
<string>com.brandonwalkin.BWToolkit</string>
<string>com.brandonwalkin.BWToolkit</string>
<string>com.brandonwalkin.BWToolkit</string>
@@ -26656,6 +26738,13 @@ aGUgYWN0aXZlIHNlbGVjdGlvbiAo4oyl4oyYUik</string>
</object>
</object>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>{{924, 496}, {156, 43}}</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>{{873, 547}, {141, 23}}</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<reference ref="9"/>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
@@ -26876,7 +26965,7 @@ Y2hhbmdlIHRoZSBvcmRlcg</string>
</object>
</object>
<nil key="sourceID"/>
- <int key="maxID">6209</int>
+ <int key="maxID">6224</int>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes">
<object class="NSMutableArray" key="referencedPartialClassDescriptions">
diff --git a/Source/TableSource.m b/Source/TableSource.m
index 04441018..f29cc6f9 100644
--- a/Source/TableSource.m
+++ b/Source/TableSource.m
@@ -924,6 +924,29 @@ fetches the result as an array with a dictionary for each row in it
}
}
+/**
+ * Menu validation
+ */
+- (BOOL)validateMenuItem:(NSMenuItem *)menuItem
+{
+ // Remove field
+ if ([menuItem action] == @selector(removeField:)) {
+ return (([tableSourceView numberOfSelectedRows] == 1) && ([tableSourceView numberOfRows] > 1));
+ }
+
+ // Duplicate field
+ if ([menuItem action] == @selector(copyField:)) {
+ return ([tableSourceView numberOfSelectedRows] == 1);
+ }
+
+ // Remove index
+ if ([menuItem action] == @selector(removeIndex:)) {
+ return ([indexView numberOfSelectedRows] == 1);
+ }
+
+ return [super validateMenuItem:menuItem];
+}
+
#pragma mark -
#pragma mark Getter methods