| 583 | } |
| 584 | |
| 585 | fn destroy_windows(&mut self) { |
| 586 | if !self.magnifier_window.is_null() { |
| 587 | unsafe { |
| 588 | if FALSE == DestroyWindow(self.magnifier_window) { |
| 589 | // |
| 590 | println!( |
| 591 | "Failed DestroyWindow magnifier window, error {}", |
| 592 | Error::last_os_error() |
| 593 | ) |
| 594 | } |
| 595 | } |
| 596 | } |
| 597 | self.magnifier_window = NULL as _; |
| 598 | |
| 599 | if !self.host_window.is_null() { |
| 600 | unsafe { |
| 601 | if FALSE == DestroyWindow(self.host_window) { |
| 602 | // |
| 603 | println!( |
| 604 | "Failed DestroyWindow host window, error {}", |
| 605 | Error::last_os_error() |
| 606 | ) |
| 607 | } |
| 608 | } |
| 609 | } |
| 610 | self.host_window = NULL as _; |
| 611 | } |
| 612 | |
| 613 | unsafe extern "C" fn on_gag_image_scaling_callback( |
| 614 | _hwnd: HWND, |