You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
41 lines
966 B
41 lines
966 B
//
|
|
// AppDelegate.swift
|
|
// rin-test
|
|
//
|
|
// Created by hrbrmstr on 8/26/19.
|
|
// Copyright © 2019 Bob Rudis. All rights reserved.
|
|
//
|
|
|
|
import Cocoa
|
|
import SwiftUI
|
|
|
|
@NSApplicationMain
|
|
class AppDelegate: NSObject, NSApplicationDelegate {
|
|
|
|
var window: NSWindow!
|
|
|
|
|
|
func applicationDidFinishLaunching(_ aNotification: Notification) {
|
|
// Insert code here to initialize your application
|
|
|
|
r_init() // INITIALIZE RInside!
|
|
|
|
window = NSWindow(
|
|
contentRect: NSRect(x: 0, y: 0, width: 480, height: 300),
|
|
styleMask: [.titled, .closable, .miniaturizable, .resizable, .fullSizeContentView],
|
|
backing: .buffered, defer: false)
|
|
window.center()
|
|
window.setFrameAutosaveName("Main Window")
|
|
|
|
window.contentView = NSHostingView(rootView: ContentView())
|
|
|
|
window.makeKeyAndOrderFront(nil)
|
|
|
|
}
|
|
|
|
func applicationWillTerminate(_ aNotification: Notification) {
|
|
// Insert code here to tear down your application
|
|
}
|
|
|
|
|
|
}
|
|
|