⚲
Project
General
Profile
Sign in
Register
Home
Projects
Help
Search
:
Wt
All Projects
Wt
Overview
Activity
Roadmap
Issues
Wiki
Forums
Download (584 Bytes)
Bug #2080
» progressive_set_initial_path_20130728a.cc
Bruce Toll
, 07/31/2013 10:32 PM
#include
<Wt/WServer>
#include
<Wt/WPushButton>
class
TestApp
:
public
Wt
::
WApplication
{
bool
update_cnt_
{
0
};
public
:
TestApp
(
const
Wt
::
WEnvironment
&
env
)
:
Wt
::
WApplication
(
env
)
{
setInternalPath
(
"/internal01"
);
auto
button
=
new
Wt
::
WPushButton
(
root
());
button
->
setText
(
"Press to update internal path."
);
button
->
clicked
().
connect
(
std
::
bind
([
=
](){
if
(
!
update_cnt_
++
)
setInternalPath
(
"/internal02"
);
}));
}
};
int
main
(
int
argc
,
char
**
argv
)
{
return
Wt
::
WRun
(
argc
,
argv
,
[](
const
Wt
::
WEnvironment
&
env
)
{
return
new
TestApp
(
env
);});
}
« Previous
1
2
Next »
(1-1/2)
Loading...