Kaydet (Commit) cbe828b7 authored tarafından jan Iversen's avatar jan Iversen

iOS, move hipernate handling to LOkit interface

Hipernate means stopping LOkit but of course saving first if a
document is active

and returning means starting LOkit again.

for now the implementation is left as FIXME

Change-Id: Id9ea2b056e87caec13c1d3fe82d4623ca3901ef2
üst 98c7ab95
......@@ -57,5 +57,26 @@ int BridgeLOkit_open(const char *path)
int BridgeLOkit_ClientCommand(const char *input)
{
return 0;
return 0;
}
int BridgeLOkit_Hipernate()
{
//FIXME
// check if document needs to be saved, to avoid data loss
// terminate all threads (basically terminate LOkit)
return 0;
}
int BridgeLOkit_LeaveHipernate()
{
//FIXME
// restart LOkit
// reload document (it may have been changed by other programs, especially if iCloud
return 0;
}
......@@ -14,3 +14,5 @@
int BridgeLOkit_Init(const char *path);
int BridgeLOkit_open(const char *path);
int BridgeLOkit_ClientCommand(const char *input);
int BridgeLOkit_Hipernate();
int BridgeLOkit_LeaveHipernate();
......@@ -15,6 +15,28 @@ import UIKit
// It is a delegate class to recieve Menu events as well as file handling events
class DocumentController: UIViewController, MenuDelegate, UIDocumentBrowserViewControllerDelegate
{
// Handling of Background (hipernate)
// iOS is not true multitasking, only 1 app can be active (foreground) at any time,
// therefore apps frequently are moved to the background.
// background really means hipernate by terminating all threads and solely keep the
// data
// Moving to hipernate
public func Hipernate() -> Void
{
BridgeLOkit_Hipernate()
}
// Moving back to foreground
public func LeaveHipernate() -> Void
{
BridgeLOkit_LeaveHipernate()
}
// handling of PropertiesController
// The PropertiesController is a left sidebar, that will scroll in when activated
// The Controller handles manipulation of properties in the document
......@@ -72,17 +94,6 @@ class DocumentController: UIViewController, MenuDelegate, UIDocumentBrowserViewC
}
}
// Handling of Background (hipernate)
public func Hipernate() -> Void
{
}
public func LeaveHipernate() -> Void
{
}
// var currentDocumentName : String?
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment