Skip to content

Instantly share code, notes, and snippets.

@iamcrypticcoder
Created March 29, 2018 09:50
Show Gist options
  • Save iamcrypticcoder/d3905c202ec5fc065aab533dfa1ad436 to your computer and use it in GitHub Desktop.
Save iamcrypticcoder/d3905c202ec5fc065aab533dfa1ad436 to your computer and use it in GitHub Desktop.
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