mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-05 03:15:07 -04:00
Handle resizing of X11 splash window correctly, and remove the annoying log2 message of download progress
This commit is contained in:
parent
e78d339a9c
commit
2ac1a3d707
@ -129,8 +129,6 @@ void P3DDownload::
|
|||||||
download_progress() {
|
download_progress() {
|
||||||
time_t now = time(NULL);
|
time_t now = time(NULL);
|
||||||
if (now != _last_reported_time || true) {
|
if (now != _last_reported_time || true) {
|
||||||
nout << "Downloading " << get_url() << ": "
|
|
||||||
<< int(get_download_progress() * 1000.0) / 10.0 << "\n";
|
|
||||||
_last_reported_time = now;
|
_last_reported_time = now;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -176,7 +176,7 @@ thread_run() {
|
|||||||
setup_gc();
|
setup_gc();
|
||||||
|
|
||||||
XEvent event;
|
XEvent event;
|
||||||
XSelectInput(_display, _window, ExposureMask);
|
XSelectInput(_display, _window, ExposureMask | StructureNotifyMask);
|
||||||
|
|
||||||
bool override = true, have_event = false;
|
bool override = true, have_event = false;
|
||||||
string prev_label;
|
string prev_label;
|
||||||
@ -186,6 +186,11 @@ thread_run() {
|
|||||||
have_event = XCheckTypedWindowEvent(_display, _window, Expose, &event)
|
have_event = XCheckTypedWindowEvent(_display, _window, Expose, &event)
|
||||||
|| XCheckTypedWindowEvent(_display, _window, GraphicsExpose, &event);
|
|| XCheckTypedWindowEvent(_display, _window, GraphicsExpose, &event);
|
||||||
|
|
||||||
|
if (XCheckTypedWindowEvent(_display, _window, ConfigureNotify, &event)) {
|
||||||
|
_width = event.xconfigure.width;
|
||||||
|
_height = event.xconfigure.height;
|
||||||
|
}
|
||||||
|
|
||||||
ACQUIRE_LOCK(_install_lock);
|
ACQUIRE_LOCK(_install_lock);
|
||||||
double install_progress = _install_progress;
|
double install_progress = _install_progress;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user