本文整理汇总了C++中THISBACK函数的典型用法代码示例。如果您正苦于以下问题:C++ THISBACK函数的具体用法?C++ THISBACK怎么用?C++ THISBACK使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了THISBACK函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: CtrlLayoutOK
ComplexStatsWin::ComplexStatsWin()
{
CtrlLayoutOK(*this, t_("Complex statistics"));
interval.Add(siDay, t_("Day"));
interval.Add(siMonth,t_("Month"));
interval.Add(siDateRange,t_("Date range"));
interval.SetData(siDay);
interval.WhenAction = THISBACK(when_interval_changes);
day_date.SetData(GetSysDate());
day_date.WhenAction = THISBACK(refresh);
month_date.SetData(GetSysDate());
month_date.Enable(false);
month_date.WhenAction = THISBACK(refresh);
date_from.SetData(GetSysDate());
date_from.Enable(false);
date_from.WhenAction = THISBACK(refresh);
date_to.SetData(GetSysDate());
date_to.Enable(false);
date_to.WhenAction = THISBACK(refresh);
products.AddColumn(NAME, t_("Product"));
products.AddColumn(NAME, t_("Count"));
clients.AddColumn(NAME, t_("Title"));
clients.AddColumn(FIRST_NAME, t_("FName"));
clients.AddColumn(LAST_NAME, t_("Surname"));
tablist.Add(products.SizePos(), t_("Sold"));
tablist.Add(clients.SizePos(), t_("Clients"));
refresh();
}
示例2: SetRect
CtrlPosTest::CtrlPosTest()
{
SetRect(Size(400,400));
Sizeable().Zoomable();
CtrlLayout(vis);
CtrlLayout(sb);
sb.Width(sb.GetSize().cx);
vis.AddFrame(sb);
vis.pc.Add(es.HCenterPos(50).VCenterPos(20));
st.SetText("STATIC");
vis.pc.Add(st.LeftPos(10,50).TopPos(20,20));
CtrlLayout(ft);
ft.Height(ft.GetSize().cy);
AddFrame(ft);
CtrlLayout(bot);
bot.Height(50);
vis.pc.AddFrame(bot);
ft.visit <<= THISBACK(VisitCB);
ft.clear <<= THISBACK(ClearCB);
ft.enable <<= THISBACK(EnableCB);
ft.disable <<= THISBACK(DisableCB);
ft.deep <<= THISBACK(DeepCB);
ft.frame <<= THISBACK(FrameCB);
ft.view <<= THISBACK(ViewCB);
ft.deep <<= true;
DeepCB();
ft.frame <<= true;
FrameCB();
ft.view <<= true;
ViewCB();
Add(sc.SizePos());
sc.AddPane(vis);
sc.WhenScrolled = callback(&hk, &CtrlPos::Update);
hk.WhenLeftSelect = THISBACK(OnSelect);
hk.SetSource(&vis);
hk.SetFocus();
}
示例3: SetGameAreaBackground
//Main game
Fifteen::Fifteen()
{
SetGameAreaBackground();
SetGameArray();
SetTimeCallback(REFRESH, THISBACK(DrawGameArea));
SetTimeCallback(-SEC, THISBACK(CountTime));
SetTimeCallback(REFRESH, THISBACK(GameOver));
SetTimeCallback(REFRESH, THISBACK(ClickTile));
newgame <<= THISBACK (SetGameArray);
solve <<= THISBACK (SolutionClick);
help <<= THISBACK(HelpClick);
CtrlLayout(*this, "Piętnastka");
}
示例4: layout
VisGenDlg::VisGenDlg(LayoutData& layout, const Vector<int>& cursor)
: layout(layout)
{
type <<= 0;
CtrlLayoutOKCancel(*this, "Code generator");
type <<= THISBACK(Type);
name <<=
pars <<=
toupper1 <<=
quotes1 <<=
name1 <<=
toupper2 <<=
quotes2 <<=
name2 <<= THISBACK(Refresh);
Refresh();
view.Highlight(CodeEditor::HIGHLIGHT_CPP);
view.HideBar();
view.SetFont(Courier(12));
if(cursor.GetCount())
sel <<= cursor;
else
for(int i = 0; i < layout.item.GetCount(); i++)
sel.Add(i);
}
示例5: GetSelected
void FormView::CreateObjectMenu(Bar& bar, int id)
{
int selCount = GetSelected().GetCount();
if (selCount > 1)
bar.Add(t_("Align selected"), THISBACK(AlignObjectMenu));
if (selCount != GetObjectCount())
bar.Add(t_("Invert selection"), THISBACK(InvertSelection));
if ((selCount != GetObjectCount()) || selCount > 1)
bar.Separator();
if (selCount == 1)
{
bar.Add(t_("Outline"), THISBACK1(ToggleOutlineDraw, id)).Check(IsOutlineDraw(id));
bar.Separator();
}
if (selCount <= 1)
{
bar.Add(t_("Top"), THISBACK1(MoveToTopObject, id));
bar.Add(t_("Up"), THISBACK1(MoveUpObject, id));
bar.Add(t_("Down"), THISBACK1(MoveDownObject, id));
bar.Add(t_("Bottom"), THISBACK1(MoveToBottomObject, id));
bar.Separator();
}
bar.Add(t_("Delete"), THISBACK(RemoveSelection));
if (selCount >= 1)
{
bar.Separator();
bar.Add(t_("Properties"), THISBACK1(OpenObjectProperties, GetSelected()));
}
}
示例6: SColorFace
NAMESPACE_UPP
#define BackColor SColorFace()
///////////////////////////////////////////////////////////////////////////////////////////////
// constructor
PixRasterBaseCtrl::PixRasterBaseCtrl(PixRasterCtrl *t, bool hScroll, bool vScroll)
{
// connects to associated RasterCtrl
pixRasterCtrl = t;
// whether control has scrollbars
hasHScrollBar = hScroll;
hasVScrollBar = vScroll;
// adds scrollbar
if(hasHScrollBar)
{
AddFrame(hScrollBar.Horz());
hScrollBar <<= THISBACK(OnScroll);
}
if(hasVScrollBar)
{
AddFrame(vScrollBar.Vert());
vScrollBar <<= THISBACK(OnScroll);
}
// marks cache as invalid
imageCache.SetValid(false);
// no marker selected
selectedMarker = NULL;
highlightMarker = NULL;
dragPolygon.Clear();
} // END constructor class PixRasterBaseCtrl
示例7: StdFont
DocEdit::DocEdit()
{
updownleave = false;
cx = 0;
filter = NULL;
after = 0;
font = StdFont();
AutoHideSb();
SetFrame(ViewFrame());
AddFrame(sb);
sb.SetLine(8);
sb.WhenScroll = THISBACK(Scroll);
InsertLines(0, 1);
eofline = true;
}
示例8: THISBACK
void LevelEditor::LoadMap()
{
Map map;
for (int i = 0; i < _pos; ++i)
map.GetLevels().Add(Level());
map.GetLevels().Add(Level(*_level));
map.SetName(_map->GetName());
EditView.LoadMap(map, true);
EditView.SetCurrentLevel(_pos);
EditView.GetCurrentLevel()->WhenChangePoint = THISBACK(OnChangePoint);
EditView.HighQuality(false);
}
示例9: CmdBuildOptionsWindow
CmdBuildOptionsWindow(const String& package, const String& method, const String& mainconfigparam, const String& output,
int targetmode, int hydra1_threads, int linkmode, bool blitzbuild, bool createmap, bool verbosebuild) :
cmdPackage(package), cmdMethod(method)
{
CtrlLayout(*this, t_("Command line options for building"));
MinimizeBox().CloseBoxRejects();
threads <<= hydra1_threads;
threads.NotNull(false);
cmdAssembly = GetVarsName();
cmdBuildMode = (targetmode == 1 ? "r" : targetmode == 2 ? "1" : targetmode == 3 ? "2" : "d");
if (mainconfigparam.GetCount()) {
cmdMainConfig = mainconfigparam;
cmdMainConfig.Replace(" ", ",");
cmdMainConfig.Insert(0, " +");
}
if (blitzbuild) blitz <<= true;
switch(linkmode) {
case 1: shared <<= true; break;
case 2: sharedbuild <<= true; break;
}
exportproject <<= 0;
map <<= createmap;
verbose <<= verbosebuild;
out <<= output;
out.SetConvert(Single<PathConvert>());
outoption <<= true;
umk <<= true;
rebuild.WhenAction = blitz.WhenAction = msgonfail.WhenAction = silent.WhenAction =
map.WhenAction = verbose.WhenAction = makefile.WhenAction =
savetargetdir.WhenAction = exportproject.WhenAction = umk.WhenAction =
threads.WhenAction = out.WhenAction = outoption.WhenAction = THISBACK(GenerateCmd);
shared.WhenAction = THISBACK(OnShared);
sharedbuild.WhenAction << THISBACK(OnSharedBuild);
btnCopy.WhenPush = callback(&cmd, &TextCtrl::Copy);
}
示例10: CtrlLayout
void SeriesTab::Init(ScatterCtrl& scatter)
{
CtrlLayout(*this);
SizePos();
pscatter = &scatter;
list.Reset();
list.SetLineCy(EditField::GetStdHeight());
list.AddColumn(t_("Name"));
for(int i = 0; i < scatter.GetCount(); i++)
list.Add(scatter.GetLegend(i));
list.SetCursor(0);
list.WhenSel = THISBACK(UpdateFields);
markstyle.Add(t_("No mark"));
for(int i = 0; i < MarkPlot::GetCount(); i++)
markstyle.Add(MarkPlot::TypeName(i));
markstyle.SetIndex(0);
UpdateFields();
linecolor <<= THISBACK(Change);
fillcolor <<= THISBACK(Change);
visible <<= THISBACK(Change);
dash <<= THISBACK(Change);
linethickness <<= THISBACK(Change);
markstyle <<= THISBACK(Change);
markcolor <<= THISBACK(Change);
markwidth <<= THISBACK(Change);
rename <<= THISBACK(Rename);
name.SetFocus();
}
示例11: THISBACK
Crush::Crush()
{
arcCrush.AddColumn(t_("Artista"));
arcCrush.AddColumn(t_("Disco"));
arcCrush.SetSortColumn(0);
arcCrush.Set(0, 0, "Morbid Angel");
arcCrush.Set(0, 1, "Domination");
arcCrush.Set(1, 0, "Cradle of Filth");
arcCrush.Set(1, 1, "The Principle of Evil Made Flesh");
btnCrush <<= THISBACK(CrushThis);
Zoomable().Sizeable();
CtrlLayout(*this, "Crush Example");
}
示例12: THISBACK
void MapEditor::OnAddLevel()
{
int row = LevelList.GetRowCount();
Level level;
level.SetName(NFormat(t_("Level #%d"), _map.GetLevels().GetCount() + 1));
level.WhenMapList = THISBACK(OnLevelMapList);
level.WhenCalculate = THISBACK1(OnLevelMapCalc, row);
if (level.OpenProperties() != IDOK)
return;
_map.GetLevels().Add(level);
UpdateLevelList();
}
示例13: THISBACK
//меню файл
void AnimeList::FileMenu(Bar& bar)
{
bar.Add("Open", CtrlImg::open(), THISBACK(Open));
bar.Add("Save", CtrlImg::save(), THISBACK(Save));
bar.Add("Save As...", CtrlImg::save_as(), THISBACK(SaveAs));
bar.Separator();
bar.Add("Close File", THISBACK(CloseFile));
bar.Separator();
bar.Add("Last File", THISBACK(OpenLastFile));
bar.Separator();
bar.Add("Print to File", CtrlImg::print(), THISBACK(PrintFile));
bar.Separator();
bar.Add("Exit", THISBACK(Quit));
}
示例14: THISBACK
void LayoutDesigner::ItemBar(Bar& bar) {
int m = itemi.GetCount();
bar.Add(layouti >= 0, "New item", THISBACK(AddItem))
.Key(K_ENTER);
bar.Add(m, "Remove item", THISBACK(Delete))
.Key(K_DELETE);
bar.Add(m, "Move item up", THISBACK(MoveUp))
.Key(K_CTRL_UP);
bar.Add(m, "Move item down", THISBACK(MoveDown))
.Key(K_CTRL_DOWN);
bar.MenuSeparator();
bar.Add("Alignment", THISBACK(AlignBar));
bar.Add("Size", THISBACK(SizeBar));
bar.Add("Springs", THISBACK(SpringsBar));
bar.MenuSeparator();
bar.Add(m, "Matrix..", THISBACK(Matrix))
.Key(K_CTRL_M);
}
示例15: CtrlLayout
void MeasuresTab::Init(ScatterCtrl& scatter) {
CtrlLayout(*this);
SizePos();
pscatter = &scatter;
xMin <<= scatter.GetXMin();
xMax <<= scatter.GetXRange() + scatter.GetXMin();
yMin <<= scatter.GetYMin();
yMax <<= scatter.GetYRange() + scatter.GetYMin();
yMin2 <<= scatter.GetYMin2();
yMax2 <<= scatter.GetY2Range() + scatter.GetYMin2();
butUpdate.WhenAction = THISBACK(Change);
Change();
}