Created
March 29, 2018 09:50
-
-
Save iamcrypticcoder/d3905c202ec5fc065aab533dfa1ad436 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class WinButton: Button { | |
var title: String? | |
func setTitle(_ title: String) -> Void { | |
self.title = title | |
} | |
func show() -> Void { | |
print("Showing Windows style button [Title: \(self.title!)]") | |
} | |
} | |
class WinWindow : Window { | |
var title: String? | |
func setTitle(_ title: String) -> Void { | |
self.title = title | |
} | |
func show() -> Void { | |
print("Showing Windows style window [Title: \(self.title!)]") | |
} | |
} | |
class OSXButton : Button { | |
var title: String? | |
func setTitle(_ title: String) -> Void { | |
self.title = title | |
} | |
func show() -> Void { | |
print("Showing OSX style button [Title: \(self.title!)]") | |
} | |
} | |
class OSXWindow : Window { | |
var title: String? | |
func setTitle(_ title: String) -> Void { | |
self.title = title | |
} | |
func show() -> Void { | |
print("Showing OSX style window [Title: \(self.title!)]") | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment