ScrollView and Scroller problem

Joined
May 19, 2008
Messages
2
Reaction score
0
Points
1
The situation is like this:
I have a subclass of NSView, which in enclosed by NSScrollView.
I don't know if I have done it right:
in init function I have:
Code:
 if ((self = [super initWithFrame:frameRect]) != nil) 
    {
        [[self enclosingScrollView] setDocumentView: self];
...
So ... when I open the window, where this nsview is drawn, the scrolling won't work till I click on the knob of the scroller (only vertical scroller). The same is when I make:
Code:
[[[self enclosingScrollView] verticalScroller] setFloatValue:value];
After that when I roll the scroller of the mouse - the NSScrollView scrolls from the last "scrolled" place.
I read that the method trackKnob "tells" the scroller that the knob has been clicked, and I tried to use it but as it seems, I can't create appropriate Event to send to it.
Anyone can help me? Pleeeease O:)
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top