Search results

  1. K

    Rewriting compare for one NSNumber object

    Hold on. I'm tired. I would just create a new class that extends from NSNumber and rewrite the compare method there. Then I would make my "initiative" object of type NewNSNumber. Right? Yeesh. Kent!
  2. K

    Rewriting compare for one NSNumber object

    I figured out another way to do it. In the method that actually calls the compare method, I put my code instead. It works. Still, if there is some other way to replace a method for a particular instance of an object I would sure like to know if it's possible. Thanks, Kent!
  3. K

    Rewriting compare for one NSNumber object

    I have an NSNumber object called "initiative" that I need to use its compare method on. Unfortunately, compare isn't doing what I thought it would so I want to rewrite it. I have no idea how to write the first line of the method, though--the declaration! I have the code I want to use...
  4. K

    How to tell if an NSTextView has been clicked away from?

    OK, I have an on-screen "form" that is used as such: 1. a table controls which item is being examined (list of names and some other info in the table). To switch which set of data is displayed in other fields on the form, one selects a different name in the table. 2. some NSTextFields...
  5. K

    Copy an object?

    Is there a simple way to copy an object in Objective C or do I need to create a new object then copy all the instance variables from the original to the new one by myself? Thanks, Kent!
  6. K

    Objective C/Cocoa - document needs to get info from a data source - how?

    What's funny is that I did connect the nextKeyView's and the order didn't change. I thought maybe I didn't understand how it works. I'll have to try again. Thanks, Kent!
  7. K

    Objective C/Cocoa - document needs to get info from a data source - how?

    YES! I DID IT! I moved everything to the document itself, and boy-oh-boy, is that better. Of course, I had some trouble at first since the methods a document runs on load are different than those a window controller or a data source runs. I had to figure out where to get the document...
  8. K

    Objective C/Cocoa - document needs to get info from a data source - how?

    OK, well, I can move the datasource data and all the datasource methods to the document, but how can I get the tableView to use the document as the datasource? As per the earlier discussion, since the windowcontroller object is the File Owner, how can I "draw" the connection from the tableview...
  9. K

    windowDidLoad - not working in one case only?

    My window controller's windowDidLoad method runs any time I create a new window, do a File | Open or double-click a saved document AS LONG AS THE APPLICATION IS ALREADY OPEN. Whenever the application is closed and I double-click one of its documents in the Finder, the application loads but...
  10. K

    Objective C/Cocoa - document needs to get info from a data source - how?

    On second look, I think I will try to move all of this to the window controller object since it makes more sense to have the data there. I mean, I already have to synchronize the data between the window controller (the active data) and the document (the data to be saved/loaded) since I have a...
  11. K

    need sample - trapping a click in a nstableview

    Great! btw: I just looked through the Help again, and found this method! I can't believe I missed it last night. Thanks again! Kent!
  12. K

    Objective C/Cocoa - document needs to get info from a data source - how?

    I actually tried using the window controller as the data source at first (since I subclassed NSWindowController, my file's owner is the window controller) but I bunged it up and decided to follow some code examples that had a seperate data source (this is my first time programming in...
  13. K

    need sample - trapping a click in a nstableview

    I need to change some various data fields in other objects in a window whenever the user clicks any particular row in a tableview. Does anyone have any sample code on how to trap the click even in the tableview? Once I know the user has clicked, I think I can get the row # with selectedrow...
  14. K

    Objective C/Cocoa - document needs to get info from a data source - how?

    I got it! From inside the window controller, this reference let me access the data source: NSMutableArray *combatants = [[[self combatTable] dataSource] combatants]; Kent!
  15. K

    Objective C/Cocoa - document needs to get info from a data source - how?

    Please help if you can. I don't have much hair left. I have a project with a document called iDMDocument, a window controller called iDMController and on my main document window I have a tableview that uses an NSObject called CombatTableDataSource as its data source. The trouble is that...
  16. K

    uControl - won't load at startup - any ideas?

    Can't be done. uControl IS a preference pane. Kent!
  17. K

    uControl - won't load at startup - any ideas?

    I really like using uControl on my iBook for the trackpad scrolling option, but it seems like I have to go into System Prefs and click on the uControl Pref at least once on each startup of my computer in order to get it to work. The load at startup option doesn't seem to be doing anything...
  18. K

    iBook G4 touchpad sensitivity

    Turning off the Clicking function seems to have worked, but damn, I like to tap to click. I guess I'll just turn it off when I need to do any real typing. Kent!
Back
Top