草庐IT

control-c

全部标签

ios - 使用 Storyboard的 swift 2.0 中的通用 Controller

我正在尝试为我的应用创建一个GenericListController。我有一个ProductListController,它扩展了这个扩展了UIViewController的通用Controller。我已将ProductListController连接到Storyboard并制作了2个socket,但我总是收到此错误:Terminatingappduetouncaughtexception'NSUnknownKeyException',reason:'[setValue:forUndefinedKey:]:thisclassisnotkeyvaluecoding-compliantf

ios - 使用 Storyboard的 swift 2.0 中的通用 Controller

我正在尝试为我的应用创建一个GenericListController。我有一个ProductListController,它扩展了这个扩展了UIViewController的通用Controller。我已将ProductListController连接到Storyboard并制作了2个socket,但我总是收到此错误:Terminatingappduetouncaughtexception'NSUnknownKeyException',reason:'[setValue:forUndefinedKey:]:thisclassisnotkeyvaluecoding-compliantf

ios - 在导航 Controller 中推送 Controller 时如何隐藏父标签栏

我有一个带有选项卡栏Controller的应用程序,每个View都包含一个导航Controller。我的主窗口如下所示:Imageherehttp://www.freeimagehosting.net/image.php?7bc867a594.png一切正常,但我注意到在将详细信息View推送到导航Controller时出现问题。在属于标签栏Controller(图像中称为Latest的那个)的tableviewcontroller的didSelectRowAtIndexPath中,我正在这样做:-(void)tableView:(UITableView*)tableViewdidSe

ios - 在导航 Controller 中推送 Controller 时如何隐藏父标签栏

我有一个带有选项卡栏Controller的应用程序,每个View都包含一个导航Controller。我的主窗口如下所示:Imageherehttp://www.freeimagehosting.net/image.php?7bc867a594.png一切正常,但我注意到在将详细信息View推送到导航Controller时出现问题。在属于标签栏Controller(图像中称为Latest的那个)的tableviewcontroller的didSelectRowAtIndexPath中,我正在这样做:-(void)tableView:(UITableView*)tableViewdidSe

objective-c - 在 View Controller 和 OS X 之间转换

我正在尝试编写一个单窗口计时器应用程序,当用户按下开始按钮时,我希望它显示另一个带有倒计时等的ViewController。我也在Xcode中使用Storyboard,在那里我有一个segue它连接开始按钮和第二个ViewController。但是,只有三种不同的样式,即模态、表单和弹出。我想将第一个ViewController替换为窗口中的第二个ViewController。我找不到办法做到这一点。我尝试为segue使用自定义样式,并在其中使用presentViewController:animator:方法,但我不知道要发送什么作为animator:的参数。在一个窗口中从一个Vie

objective-c - 在 View Controller 和 OS X 之间转换

我正在尝试编写一个单窗口计时器应用程序,当用户按下开始按钮时,我希望它显示另一个带有倒计时等的ViewController。我也在Xcode中使用Storyboard,在那里我有一个segue它连接开始按钮和第二个ViewController。但是,只有三种不同的样式,即模态、表单和弹出。我想将第一个ViewController替换为窗口中的第二个ViewController。我找不到办法做到这一点。我尝试为segue使用自定义样式,并在其中使用presentViewController:animator:方法,但我不知道要发送什么作为animator:的参数。在一个窗口中从一个Vie

ios - Swift——在 App Delegate 中实例化一个没有 Storyboard的导航 Controller

我正在重建一个没有Storyboard的应用程序,其中我遇到最大麻烦的部分是以编程方式导航View到View。那里写的东西很少不使用Storyboard,因此很难找到答案。我的问题很简单。我有我的ViewController和我的SecondViewController,我想从前者推送到后者。在AppDelegate中:funcapplication(application:UIApplication,didFinishLaunchingWithOptionslaunchOptions:[NSObject:AnyObject]?)->Bool{//Overridepointforcus

ios - Swift——在 App Delegate 中实例化一个没有 Storyboard的导航 Controller

我正在重建一个没有Storyboard的应用程序,其中我遇到最大麻烦的部分是以编程方式导航View到View。那里写的东西很少不使用Storyboard,因此很难找到答案。我的问题很简单。我有我的ViewController和我的SecondViewController,我想从前者推送到后者。在AppDelegate中:funcapplication(application:UIApplication,didFinishLaunchingWithOptionslaunchOptions:[NSObject:AnyObject]?)->Bool{//Overridepointforcus

swift - 将 swift 文件添加到 xCode 中的新 View Controller ? (简单的)

我刚开始使用xCode6,我似乎无法弄清楚如何将新的swift-file添加到我在界面构建器中添加的新ViewController。如有任何关于如何进行的提示,我们将不胜感激。 最佳答案 添加一个新的CocoaTouch类。从菜单中选择文件->新建->文件...。为这个新类命名,例如“ViewController2”,并将Subclassof:弹出设置为UIViewController。将创建文件“ViewController2.swift”。在InterfaceBuilder中点击您的新ViewController。在Identi

swift - 将 swift 文件添加到 xCode 中的新 View Controller ? (简单的)

我刚开始使用xCode6,我似乎无法弄清楚如何将新的swift-file添加到我在界面构建器中添加的新ViewController。如有任何关于如何进行的提示,我们将不胜感激。 最佳答案 添加一个新的CocoaTouch类。从菜单中选择文件->新建->文件...。为这个新类命名,例如“ViewController2”,并将Subclassof:弹出设置为UIViewController。将创建文件“ViewController2.swift”。在InterfaceBuilder中点击您的新ViewController。在Identi