|
Mods: Keeping Current Selection In View |
|
Written by Dream Dancer
|
|
Jul 08, 2010 at 01:03 PM |
|
Got annoyed by the fact that I never put in code to rescroll the selected element(s) back into view in either the shape list when swapping stuff, or in the kitterspeak list when inserting or editing stuff. Was really simple to do, just never got around to doing it.
- in menuShapeSwapFrames_Click
- under FoxList.ListItems(PointerTo).Selected = True
- add FoxList.ListItems(PointerTo).EnsureVisible
And likewise;
- in menuShapeSwapShapes_Click
- under FoxList.ListItems(PointerTo).Selected = True
- add FoxList.ListItems(PointerTo).EnsureVisible
And tada, that now works as expected. And the kitterspeak scrolling into view is just as simple, with getting the current listindex, then selecting it to become the visible line.
- in DoPasteKitterSpeak
- add Dim cSelect As Long
- under If KitterEdits.NumSteps = 0 Then Exit Sub
- add cSelect = KitterSpeakList.SelectedItem.Index
- further down under FillKitterList Fox.Shape(CurrentShape).Steps, CurrentShape
- add KitterSpeakList.ListItems(cSelect).EnsureVisible
And I'm happy with that. Last one to wrap up this.
- in KitterButton_Click
- under FillKitterList KitterEdits.Steps, CurrentShape
- add KitterSpeakList.ListItems(KitterEditStep).EnsureVisible
And that should do it for this mod. |
|
Last Updated ( Jul 08, 2010 at 01:05 PM )
|