Re: View-based NSTableView strange scrolling behavior.
Re: View-based NSTableView strange scrolling behavior.
- Subject: Re: View-based NSTableView strange scrolling behavior.
- From: Fritz Anderson <email@hidden>
- Date: Fri, 02 Nov 2012 11:15:06 -0500
I may be misunderstanding what you mean by
> After run that simple app works improperly.
Does that mean you've fixed the simple app and its behavior still wrong? Or do you mean you haven't and want us to debug your "real code" without knowing anything about it?
If you have now implemented all the mandatory methods in the simple app, and it still does not work, then you have learned something. Work on the simple app until it works properly. You will have learned something more, and can apply what you've learned to the real one.
If you have _not_ implemented all the mandatory methods in the simple app, you do not have a test case. You will learn nothing from your simple application until you have provided the data-source methods you MUST provide. If you don't, then all you can do is to repeat your question about your main program over and over again ("How do you explain that…").
Doing what must be done will cost you five minutes. Once you've done the test code correctly, you'll know what part of your code is going wrong.
Humor us.
— F
On 1 Nov 2012, at 9:30 PM, Dmitriy Balakirev <email@hidden> wrote:
> How your explain that:
> After run that simple app works improperly. Then, I press Home button - now that same app works very properly?
> What magic happens when I press Home (End)?
>
> In real code the scroll behavior is exactly the same.
>
> 02.11.2012, в 6:14, Graham Cox <email@hidden> написал(а):
>
>>
>> On 02/11/2012, at 1:08 PM, Dmitriy Balakirev <email@hidden> wrote:
>>
>>> - (NSInteger)numberOfRowsInTableView:(NSTableView *)tableView {
>>> return 1000;
>>> }
>>> is the only code added to the cocoa application template. Then I drop table to window, set number of columns to 10 and connect app delegate as table datasource.
>>> But question not about how to implement nstableview datasource. It is about why table view properly scroll (using keyboard arrow keys) ONLY AFTER I press Home or End buttons.
>>
>>
>> Well, your datasource MUST implement the MANDATORY methods. If it doesn't the table will not behave properly. You seem to think it doesn't matter that your datasource is wrong; I suggest it is entirely the reason for your problems. If you don't implement things as they are required to be implemented, you can't ignore that fact and still expect things to work.
>>
>> You must also be ignoring warnings either at compile and/or run time that your datasource is insufficient, which are trying to tell you what the problem is.
>>
>> --Graham
>
> _______________________________________________
>
> Cocoa-dev mailing list (email@hidden)
>
> Please do not post admin requests or moderator comments to the list.
> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden