masakih

OSXを起動したらそこには『艦隊これくしょん -艦これ-』の世界が広がっていたのです!?

  • R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

Commit MetaInfo

Revision5755e6f0c5b4647d89477a15ce9b8898b5869c62 (tree)
Zeit2018-04-18 22:33:19
Autormasakih <masakih@user...>
Commitermasakih

Log Message

swift4.3に更新

Ändern Zusammenfassung

Diff

--- a/KanColleBrowserForOSX.xcodeproj/project.pbxproj
+++ b/KanColleBrowserForOSX.xcodeproj/project.pbxproj
@@ -169,11 +169,11 @@
169169 TargetAttributes = {
170170 F4EF18AE1B4D36E60021BF8D = {
171171 CreatedOnToolsVersion = 6.4;
172- LastSwiftMigration = 0810;
172+ LastSwiftMigration = 0930;
173173 };
174174 F4EF18BE1B4D36E60021BF8D = {
175175 CreatedOnToolsVersion = 6.4;
176- LastSwiftMigration = 0810;
176+ LastSwiftMigration = 0930;
177177 TestTargetID = F4EF18AE1B4D36E60021BF8D;
178178 };
179179 };
@@ -389,7 +389,8 @@
389389 LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks";
390390 PRODUCT_BUNDLE_IDENTIFIER = "com.masakih.$(PRODUCT_NAME:rfc1034identifier)";
391391 PRODUCT_NAME = "$(TARGET_NAME)";
392- SWIFT_VERSION = 3.0;
392+ SWIFT_SWIFT3_OBJC_INFERENCE = On;
393+ SWIFT_VERSION = 4.0;
393394 };
394395 name = Debug;
395396 };
@@ -402,7 +403,8 @@
402403 LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks";
403404 PRODUCT_BUNDLE_IDENTIFIER = "com.masakih.$(PRODUCT_NAME:rfc1034identifier)";
404405 PRODUCT_NAME = "$(TARGET_NAME)";
405- SWIFT_VERSION = 3.0;
406+ SWIFT_SWIFT3_OBJC_INFERENCE = On;
407+ SWIFT_VERSION = 4.0;
406408 };
407409 name = Release;
408410 };
@@ -423,7 +425,8 @@
423425 LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/../Frameworks";
424426 PRODUCT_BUNDLE_IDENTIFIER = "com.masakih.$(PRODUCT_NAME:rfc1034identifier)";
425427 PRODUCT_NAME = "$(TARGET_NAME)";
426- SWIFT_VERSION = 3.0;
428+ SWIFT_SWIFT3_OBJC_INFERENCE = On;
429+ SWIFT_VERSION = 4.0;
427430 TEST_HOST = "$(BUILT_PRODUCTS_DIR)/KanColleBrowserForOSX.app/Contents/MacOS/KanColleBrowserForOSX";
428431 };
429432 name = Debug;
@@ -441,7 +444,8 @@
441444 LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/../Frameworks";
442445 PRODUCT_BUNDLE_IDENTIFIER = "com.masakih.$(PRODUCT_NAME:rfc1034identifier)";
443446 PRODUCT_NAME = "$(TARGET_NAME)";
444- SWIFT_VERSION = 3.0;
447+ SWIFT_SWIFT3_OBJC_INFERENCE = On;
448+ SWIFT_VERSION = 4.0;
445449 TEST_HOST = "$(BUILT_PRODUCTS_DIR)/KanColleBrowserForOSX.app/Contents/MacOS/KanColleBrowserForOSX";
446450 };
447451 name = Release;
--- a/KanColleBrowserForOSX/KCBFOMainWindowController.swift
+++ b/KanColleBrowserForOSX/KCBFOMainWindowController.swift
@@ -20,7 +20,7 @@ class KCBFOMainWindowController: NSWindowController {
2020
2121 class func makeInstance() -> KCBFOMainWindowController {
2222
23- return KCBFOMainWindowController(windowNibName: "KCBFOMainWindowController")
23+ return KCBFOMainWindowController(windowNibName: NSNib.Name(rawValue: "KCBFOMainWindowController"))
2424 }
2525
2626
@@ -73,6 +73,7 @@ class KCBFOMainWindowController: NSWindowController {
7373
7474 return
7575 }
76+
7677 // ゲームページでない場合はゲームページを表示する
7778 if let url = webView?.url, url.absoluteString != gamePageURL {
7879
@@ -109,7 +110,7 @@ class KCBFOMainWindowController: NSWindowController {
109110
110111 func webView(_ sender: WebView!, contextMenuItemsForElement element: [AnyHashable: Any]!, defaultMenuItems: [AnyObject]!) -> [Any]! {
111112
112- return defaultMenuItems.flatMap() {
113+ return defaultMenuItems.compactMap {
113114
114115 if ignoreTags.contains($0.tag) {
115116