equal
deleted
inserted
replaced
690 num -= w->vscroll.cap; |
690 num -= w->vscroll.cap; |
691 if (num < 0) num = 0; |
691 if (num < 0) num = 0; |
692 if (num < w->vscroll.pos) w->vscroll.pos = num; |
692 if (num < w->vscroll.pos) w->vscroll.pos = num; |
693 } |
693 } |
694 |
694 |
|
695 void SetVScroll2Count(Window *w, int num) |
|
696 { |
|
697 w->vscroll2.count = num; |
|
698 num -= w->vscroll2.cap; |
|
699 if (num < 0) num = 0; |
|
700 if (num < w->vscroll2.pos) w->vscroll2.pos = num; |
|
701 } |
|
702 |
695 void SetHScrollCount(Window *w, int num) |
703 void SetHScrollCount(Window *w, int num) |
696 { |
704 { |
697 w->hscroll.count = num; |
705 w->hscroll.count = num; |
698 num -= w->hscroll.cap; |
706 num -= w->hscroll.cap; |
699 if (num < 0) num = 0; |
707 if (num < 0) num = 0; |
700 if (num < w->hscroll.pos) w->hscroll.pos = num; |
708 if (num < w->hscroll.pos) w->hscroll.pos = num; |
701 } |
709 } |
702 |
|
703 |
710 |
704 int HandleEditBoxKey(Window *w, int wid, WindowEvent *we) |
711 int HandleEditBoxKey(Window *w, int wid, WindowEvent *we) |
705 { |
712 { |
706 byte *p; |
713 byte *p; |
707 int width,count; |
714 int width,count; |