summaryrefslogtreecommitdiffstats
path: root/ios/LibreOfficeLight/LibreOfficeLight/AppDelegate.swift
diff options
context:
space:
mode:
Diffstat (limited to 'ios/LibreOfficeLight/LibreOfficeLight/AppDelegate.swift')
-rw-r--r--ios/LibreOfficeLight/LibreOfficeLight/AppDelegate.swift10
1 files changed, 6 insertions, 4 deletions
diff --git a/ios/LibreOfficeLight/LibreOfficeLight/AppDelegate.swift b/ios/LibreOfficeLight/LibreOfficeLight/AppDelegate.swift
index 12e596bc030d..9bdc1fefa48e 100644
--- a/ios/LibreOfficeLight/LibreOfficeLight/AppDelegate.swift
+++ b/ios/LibreOfficeLight/LibreOfficeLight/AppDelegate.swift
@@ -39,14 +39,14 @@ class AppDelegate: UIResponder, UIApplicationDelegate
let appInfo = Bundle.main.infoDictionary! as Dictionary<String,AnyObject>
let applicationVersion = (appInfo["CFBundleShortVersionString"] as! String) + "." +
(appInfo["CFBundleVersion"] as! String)
+
+ // Add version string to setting
let defaults = UserDefaults.standard
defaults.set(applicationVersion, forKey: "application_version")
defaults.synchronize()
// start LibreOfficeKit
//FIX BridgeLOkit_Init(Bundle.main.bundlePath)
- //FIX BridgeLOkit_open("jan");
- //FIX BridgeLOkit_ClientCommand("jan");
return true
}
@@ -72,7 +72,8 @@ class AppDelegate: UIResponder, UIApplicationDelegate
// this method is called instead of applicationWillTerminate: when the user quits.
func applicationDidEnterBackground(_ application: UIApplication)
{
- // Jan to do done (scale down LO)
+ let document = window?.rootViewController?.childViewControllers[0] as! DocumentController
+ document.Hipernate()
}
@@ -81,7 +82,8 @@ class AppDelegate: UIResponder, UIApplicationDelegate
// Restart timers, tasks as well as graphic rendering
func applicationWillEnterForeground(_ application: UIApplication)
{
- // Jan to be done (reactivate LO)
+ let document = window?.rootViewController?.childViewControllers[0] as! DocumentController
+ document.LeaveHipernate()
}