[sword-svn] r3838 - in trunk/bindings: cordova/cordova-plugin-crosswire-sword/src/ios objc/SWORD/SWORD.xcodeproj/project.xcworkspace/xcuserdata/scribe.xcuserdatad

scribe at crosswire.org scribe at crosswire.org
Sun Dec 27 14:10:29 EST 2020


Author: scribe
Date: 2020-12-27 14:10:28 -0500 (Sun, 27 Dec 2020)
New Revision: 3838

Modified:
   trunk/bindings/cordova/cordova-plugin-crosswire-sword/src/ios/SWORD.swift
   trunk/bindings/objc/SWORD/SWORD.xcodeproj/project.xcworkspace/xcuserdata/scribe.xcuserdatad/UserInterfaceState.xcuserstate
Log:
updated to the Swift bindings for SWORD to facilitate the new terminateSearch method in the Cordova plugin


Modified: trunk/bindings/cordova/cordova-plugin-crosswire-sword/src/ios/SWORD.swift
===================================================================
--- trunk/bindings/cordova/cordova-plugin-crosswire-sword/src/ios/SWORD.swift	2020-12-26 18:26:12 UTC (rev 3837)
+++ trunk/bindings/cordova/cordova-plugin-crosswire-sword/src/ios/SWORD.swift	2020-12-27 19:10:28 UTC (rev 3838)
@@ -350,7 +350,7 @@
                 "name": vkInfo[VERSEKEY_BOOKNAME],
                 "abbrev": vkInfo[VERSEKEY_BOOKABBREV],
                 "osisName": vkInfo[VERSEKEY_OSISBOOKNAME],
-                "chapterMax": Int(vkInfo[VERSEKEY_CHAPTERMAX]),
+                "chapterMax": Int(vkInfo[VERSEKEY_CHAPTERMAX])!,
             ] as [AnyHashable : Any]
             retVal.append(bookInfo)
 
@@ -671,7 +671,7 @@
         let saveMasterKey = String(cString: org_crosswire_sword_SWModule_getKeyText(masterMod))
         let saveKey = String(cString: org_crosswire_sword_SWModule_getKeyText(mod))
         var r = [[String: Any]]()
-        var currentKey = getStringArray(buffer: org_crosswire_sword_SWModule_getKeyChildren(masterMod))
+        let currentKey = getStringArray(buffer: org_crosswire_sword_SWModule_getKeyChildren(masterMod))
         let book = currentKey[VERSEKEY_BOOKABBREV]
         let chapter = currentKey[VERSEKEY_CHAPTER]
         org_crosswire_sword_SWModule_setKeyText(masterMod, book + "." + chapter + ".1")
@@ -725,7 +725,7 @@
     }
 
     @objc(SWModule_terminateSearch:)
-    func SWModule_setKeyText(command: CDVInvokedUrlCommand) {
+    func SWModule_terminateSearch(command: CDVInvokedUrlCommand) {
         let module = getModule(command: command)
         if (module != 0) {
             org_crosswire_sword_SWModule_terminateSearch(module)

Modified: trunk/bindings/objc/SWORD/SWORD.xcodeproj/project.xcworkspace/xcuserdata/scribe.xcuserdatad/UserInterfaceState.xcuserstate
===================================================================
(Binary files differ)



More information about the sword-cvs mailing list