mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-05-15 14:16:07 -06:00
ide: Alt+C (copy declaration/definition) refactored, CtrlLib: DisplayPopUp issues
This commit is contained in:
parent
b572d8be79
commit
27c4cdef51
9 changed files with 213 additions and 22 deletions
|
|
@ -13,8 +13,33 @@ GUI_APP_MAIN
|
|||
dl.Add("Simple");
|
||||
for(int i = 0; i < 10; i++)
|
||||
dl.Add("Long " + String('X', i * 100));
|
||||
|
||||
TreeCtrl tree;
|
||||
Vector<int> parent, parent2;
|
||||
parent.Add(0);
|
||||
tree.SetRoot(Image(), "The Tree");
|
||||
Array<Option> option;
|
||||
for(int i = 1; i < 10000; i++) {
|
||||
parent.Add(tree.Add(parent[rand() % parent.GetCount()],
|
||||
i & 1 ? CtrlImg::open() : Image(),
|
||||
FormatIntRoman(i, true)));
|
||||
if((rand() & 3) == 0)
|
||||
tree.Open(parent.Top());
|
||||
}
|
||||
tree.Open(0);
|
||||
tree.MultiSelect().ScrollIntoX();
|
||||
|
||||
ColumnList clist;
|
||||
clist.Columns(3);
|
||||
clist.MultiSelect();
|
||||
|
||||
for(int i = 0; i < 500; i++)
|
||||
clist.Add(FormatIntRoman(i));
|
||||
|
||||
TopWindow win;
|
||||
win.Add(dl.TopPosZ(0).LeftPosZ(0, 100));
|
||||
win.Add(list.VSizePosZ(Zx(20), 0).LeftPosZ(0, 100));
|
||||
win.Add(tree.VSizePosZ(Zx(20), 0).LeftPosZ(100, 100));
|
||||
win.Add(clist.VSizePosZ(Zx(20), 0).LeftPosZ(200, 100));
|
||||
win.Run();
|
||||
}
|
||||
|
|
|
|||
41
upptst/ide_alt_c/ide.cpp
Normal file
41
upptst/ide_alt_c/ide.cpp
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
#include <Core/Core.h>
|
||||
|
||||
using namespace Upp;
|
||||
|
||||
#include <Core/Core.h>
|
||||
|
||||
#include <algorithm>
|
||||
#include <vector>
|
||||
#include <set>
|
||||
#include <utility>
|
||||
|
||||
struct Foo {
|
||||
struct Change { int foo;
|
||||
int Test();
|
||||
};
|
||||
struct Item { int foo; };
|
||||
|
||||
std::vector<String> Bar2(const std::vector<Item>& price, String s);
|
||||
std::vector<Change> Bar(const std::vector<Item>& price, String s);
|
||||
std::vector<Foo::Change> Bar(const std::vector<std::vector<Item>>& price, String s);
|
||||
std::vector<void (*)(int x, int y)> Bar(const std::vector<std::vector<Item>>& price, int x);
|
||||
};
|
||||
|
||||
namespace Test {
|
||||
struct Foo {
|
||||
struct Change { int foo;
|
||||
int Test();
|
||||
};
|
||||
struct Item { int foo; };
|
||||
|
||||
std::vector<String> Bar2(const std::vector<Item>& price, String s);
|
||||
std::vector<Change> Bar(const std::vector<Item>& price, String s);
|
||||
std::vector<Foo::Change> Bar(const std::vector<std::vector<Item>>& price, String s);
|
||||
std::vector<void (*)(int x, int y)> Bar(const std::vector<std::vector<Item>>& price, int x);
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
CONSOLE_APP_MAIN
|
||||
{
|
||||
}
|
||||
9
upptst/ide_alt_c/ide_alt_c.upp
Normal file
9
upptst/ide_alt_c/ide_alt_c.upp
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
uses
|
||||
Core;
|
||||
|
||||
file
|
||||
ide.cpp;
|
||||
|
||||
mainconfig
|
||||
"" = "";
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue