Patch level : 12.0 338
Files correlati : I progress indicator non ridavano il focus all'interfaccia. git-svn-id: svn://10.65.10.50/branches/R_10_00@23578 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
c4b8fb1005
commit
22b1c38c7b
@ -370,6 +370,8 @@ void TProgress_monitor::set_max(long tot)
|
|||||||
bool TProgress_monitor::is_cancelled() const
|
bool TProgress_monitor::is_cancelled() const
|
||||||
{ return _cancelled; }
|
{ return _cancelled; }
|
||||||
|
|
||||||
|
static WINDOW topwin = NULL;
|
||||||
|
|
||||||
TProgress_monitor::TProgress_monitor(long items, const char* txt, bool cancancel)
|
TProgress_monitor::TProgress_monitor(long items, const char* txt, bool cancancel)
|
||||||
: _total(items), _txt(txt), _status(0), _cancellable(cancancel),
|
: _total(items), _txt(txt), _status(0), _cancellable(cancancel),
|
||||||
_pd(NULL_WIN), _start(clock()), _cancelled(false)
|
_pd(NULL_WIN), _start(clock()), _cancelled(false)
|
||||||
@ -377,6 +379,7 @@ TProgress_monitor::TProgress_monitor(long items, const char* txt, bool cancancel
|
|||||||
xvt_scr_set_busy_cursor();
|
xvt_scr_set_busy_cursor();
|
||||||
if (_pm_parent == NULL_WIN)
|
if (_pm_parent == NULL_WIN)
|
||||||
{
|
{
|
||||||
|
topwin = xvt_scr_get_focus_topwin();
|
||||||
_pm_parent = cur_win();
|
_pm_parent = cur_win();
|
||||||
if (_pm_parent == NULL_WIN)
|
if (_pm_parent == NULL_WIN)
|
||||||
_pm_parent = TASK_WIN;
|
_pm_parent = TASK_WIN;
|
||||||
@ -399,4 +402,11 @@ TProgress_monitor::~TProgress_monitor()
|
|||||||
xvt_dm_progress_destroy(_pd);
|
xvt_dm_progress_destroy(_pd);
|
||||||
else
|
else
|
||||||
xvt_scr_reset_busy_cursor();
|
xvt_scr_reset_busy_cursor();
|
||||||
|
CHECK("top_win NULL", topwin != NULL_WIN);
|
||||||
|
if (_pm_inst <= 0 && topwin != NULL_WIN)
|
||||||
|
{
|
||||||
|
xvt_scr_set_focus_vobj(topwin);
|
||||||
|
xvt_vobj_raise(topwin);
|
||||||
|
topwin = NULL_WIN;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user