mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-05-21 06:45:39 -06:00
.theide/SrcUpdater: Fixed scrolling
git-svn-id: svn://ultimatepp.org/upp/trunk@3462 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
02899206c2
commit
7407384b9c
2 changed files with 9 additions and 6 deletions
|
|
@ -43,7 +43,7 @@ void SaveHashes(const String& fn,VectorMap<String,synchashes>& src, int c){
|
|||
f.Close();
|
||||
}
|
||||
|
||||
LocalSync::LocalSync(){
|
||||
LocalSync::LocalSync() : row(0){
|
||||
CtrlLayoutOKCancel(*this, "Synchronize local sources");
|
||||
list.AddColumn("State");
|
||||
list.AddColumn("Actions");
|
||||
|
|
@ -74,11 +74,11 @@ LocalSync::LocalSync(){
|
|||
}
|
||||
|
||||
void LocalSync::Menu(Bar& bar){
|
||||
int i = list.GetClickRow();
|
||||
if(i>=list.GetCount() || i<0) return;
|
||||
i = list.Get(i,4);
|
||||
if(i<0) return;
|
||||
String file = files.GetKey(i);
|
||||
row = list.GetClickRow();
|
||||
if(row>=list.GetCount() || row<0) return;
|
||||
row = list.Get(row,4);
|
||||
if(row<0) return;
|
||||
String file = files.GetKey(row);
|
||||
|
||||
for(int j=0; j<file.GetCount(); j++)
|
||||
if(file[j]=='/'){
|
||||
|
|
@ -111,6 +111,7 @@ void LocalSync::SetAction(const String& str, int action){
|
|||
s<<=cs[action].value;
|
||||
}
|
||||
}
|
||||
list.ScrollInto(row);
|
||||
}
|
||||
|
||||
void LocalSync::Manage(){
|
||||
|
|
@ -275,4 +276,5 @@ void LocalSync::Populate(const VectorMap<String,synchashes>& files){
|
|||
if(r==0){
|
||||
list.Add("", Null, AttrText("No changes in the installed nests").SetFont(StdFont().Italic()),Null,Null);
|
||||
}
|
||||
list.ScrollInto(row);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -80,6 +80,7 @@ struct LocalSync : WithSvnSyncLayout<TopWindow> {
|
|||
Array<Switch> switches;
|
||||
Array<Button> btns;
|
||||
VectorMap<String,synchashes> files;
|
||||
int row;
|
||||
|
||||
typedef LocalSync CLASSNAME;
|
||||
void DoShowFile(const String& l,const String& g);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue