]> git.lyx.org Git - features.git/blobdiff - src/support/AppleSupport.m
Revert "WIP: refactor Systemcall"
[features.git] / src / support / AppleSupport.m
index 3a4f864e8e44420a0f8f879aebc24092d6bf02c3..4278564a45f55e5b35ec4035a2122ea9fb95aead 100644 (file)
@@ -42,6 +42,26 @@ void appleCleanupViewMenu() {
 
 
 bool appleUserTabbingPreferenceAlways() {
+#if defined(__MAC_OS_X_VERSION_MAX_ALLOWED) && (__MAC_OS_X_VERSION_MAX_ALLOWED >= 101200)
        return [NSWindow respondsToSelector:@selector(userTabbingPreference)] &&
                [NSWindow userTabbingPreference] == NSWindowUserTabbingPreferenceAlways;
+#else
+       return false;
+#endif
+}
+
+
+int NSTextInsertionPointBlinkPeriodOn() {
+       NSUserDefaults *prefs = [NSUserDefaults standardUserDefaults];
+
+       return [prefs objectForKey:@"NSTextInsertionPointBlinkPeriodOn"] == nil ?
+               -1 : [prefs floatForKey:@"NSTextInsertionPointBlinkPeriodOn"];
+}
+
+
+int NSTextInsertionPointBlinkPeriodOff() {
+       NSUserDefaults *prefs = [NSUserDefaults standardUserDefaults];
+
+       return [prefs objectForKey:@"NSTextInsertionPointBlinkPeriodOff"] == nil ?
+                       -1 : [prefs floatForKey:@"NSTextInsertionPointBlinkPeriodOff"];
 }