1
1
mirror of https://github.com/qvacua/vimr.git synced 2024-11-24 11:37:32 +03:00

GH-228 Hide debug menu item in Release config

This commit is contained in:
Tae Won Ha 2016-08-09 22:29:46 +02:00
parent 1194b3f8cf
commit 71fdb30f62
No known key found for this signature in database
GPG Key ID: E40743465B5B8B44
3 changed files with 14 additions and 3 deletions

View File

@ -947,6 +947,7 @@
MACOSX_DEPLOYMENT_TARGET = 10.11;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
OTHER_SWIFT_FLAGS = "-D DEBUG";
SDKROOT = macosx;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
VERSIONING_SYSTEM = "apple-generic";

View File

@ -10,6 +10,8 @@ import PureLayout
@NSApplicationMain
class AppDelegate: NSObject, NSApplicationDelegate {
@IBOutlet var debugMenu: NSMenuItem!
private let disposeBag = DisposeBag()
private let changeSubject = PublishSubject<Any>()
@ -52,6 +54,10 @@ class AppDelegate: NSObject, NSApplicationDelegate {
// self.window.contentView?.addSubview(testView)
// self.window.makeFirstResponder(testView)
#if DEBUG
self.debugMenu.hidden = false
#endif
self.newDocument(self)
}

View File

@ -12,7 +12,11 @@
</customObject>
<customObject id="-1" userLabel="First Responder" customClass="FirstResponder"/>
<customObject id="-3" userLabel="Application" customClass="NSObject"/>
<customObject id="Voe-Tx-rLC" customClass="AppDelegate" customModule="VimR" customModuleProvider="target"/>
<customObject id="Voe-Tx-rLC" customClass="AppDelegate" customModule="VimR" customModuleProvider="target">
<connections>
<outlet property="debugMenu" destination="RmS-Zn-Snd" id="anN-h2-97s"/>
</connections>
</customObject>
<menu title="Main Menu" systemMenu="main" id="AYu-sK-qS6">
<items>
<menuItem title="VimR" id="1Xt-HY-uBw">
@ -204,11 +208,11 @@
</items>
</menu>
</menuItem>
<menuItem title="Debug" id="RmS-Zn-Snd">
<menuItem title="Debug" hidden="YES" id="RmS-Zn-Snd">
<modifierMask key="keyEquivalentModifierMask"/>
<menu key="submenu" title="Debug" id="FMz-3N-3Eu">
<items>
<menuItem title="Debug1" id="IFh-6Q-w93">
<menuItem title="Debug 1" id="IFh-6Q-w93">
<modifierMask key="keyEquivalentModifierMask"/>
<connections>
<action selector="debug1:" target="-1" id="OSW-j0-HVo"/>