[ekiga] Call Window: Disable too small video display.



commit d4385cc36711d5bf47290f0b59ff6eee44a10af7
Author: Damien Sandras <dsandras beip be>
Date:   Sun Feb 5 14:28:59 2012 +0100

    Call Window: Disable too small video display.
    
    There is now some sort of a minimal zoom in when displayed video is too
    small (like QCIF).

 src/gui/call_window.cpp |   12 ++++++++++++
 1 files changed, 12 insertions(+), 0 deletions(-)
---
diff --git a/src/gui/call_window.cpp b/src/gui/call_window.cpp
index d288269..15104e1 100644
--- a/src/gui/call_window.cpp
+++ b/src/gui/call_window.cpp
@@ -842,6 +842,18 @@ on_size_changed_cb (Ekiga::VideoOutputManager & /* manager */,
 
   ekiga_call_window_set_video_size (EKIGA_CALL_WINDOW (cw), width, height);
 
+  // If the video is too small, enable automatic zooming
+  if (width <= GM_QCIF_WIDTH && height <= GM_QCIF_HEIGHT) {
+    Ekiga::DisplayInfo display_info;
+    display_info.zoom = gm_conf_get_int (VIDEO_DISPLAY_KEY "zoom");
+
+    if (display_info.zoom < 200)
+      display_info.zoom = display_info.zoom * 2;
+
+    gm_conf_set_int (VIDEO_DISPLAY_KEY "zoom", display_info.zoom);
+    ekiga_call_window_zooms_menu_update_sensitivity (cw, display_info.zoom);
+  }
+
   gtk_widget_show_all (GTK_WIDGET (cw));
 }
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]