[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[linterna-magica-commit] [348] Force min height and width.
From: |
Ivaylo Valkov |
Subject: |
[linterna-magica-commit] [348] Force min height and width. |
Date: |
Fri, 21 Dec 2012 09:07:08 +0000 |
Revision: 348
http://svn.sv.gnu.org/viewvc/?view=rev&root=linterna-magica&revision=348
Author: valkov
Date: 2012-12-21 09:07:08 +0000 (Fri, 21 Dec 2012)
Log Message:
-----------
Force min height and width. Tasks #12203.
Ticket Links:
------------
http://savannah.gnu.org/task/?12203
Modified Paths:
--------------
trunk/src/lm_constructors.js
trunk/src/lm_create_video_object.js
trunk/src/lm_extract_dom_objects.js
Modified: trunk/src/lm_constructors.js
===================================================================
--- trunk/src/lm_constructors.js 2012-12-21 08:29:51 UTC (rev 347)
+++ trunk/src/lm_constructors.js 2012-12-21 09:07:08 UTC (rev 348)
@@ -235,11 +235,9 @@
// One close button after the logo (1x24)
LinternaMagica.prototype.min_height = 212;
-// Buttons (8x24)
-// Volume slider when visible (1x83)
-// Time text (1x78)
-LinternaMagica.prototype.min_width = 353;
+LinternaMagica.prototype.min_width = 400;
+
// One close button (1x24)
// One logo button (1x146)
// 1px border
Modified: trunk/src/lm_create_video_object.js
===================================================================
--- trunk/src/lm_create_video_object.js 2012-12-21 08:29:51 UTC (rev 347)
+++ trunk/src/lm_create_video_object.js 2012-12-21 09:07:08 UTC (rev 348)
@@ -32,8 +32,21 @@
LinternaMagica.prototype.create_video_object = function(object_data)
{
if (typeof(object_data) !== "object")
+ {
return;
+ }
+ if (object_data.width < this.min_width)
+ {
+ object_data.width = this.min_width;
+ }
+
+ if (object_data.height < this.min_height)
+ {
+ object_data.height = this.min_height;
+ }
+
+
var toggle_plugin = null;
var id = object_data.linterna_magica_id;
Modified: trunk/src/lm_extract_dom_objects.js
===================================================================
--- trunk/src/lm_extract_dom_objects.js 2012-12-21 08:29:51 UTC (rev 347)
+++ trunk/src/lm_extract_dom_objects.js 2012-12-21 09:07:08 UTC (rev 348)
@@ -318,7 +318,7 @@
// Find the flash object width
LinternaMagica.prototype.extract_object_width =
-function(element, dont_force_min)
+function(element)
{
if (!/HTML(embed|iframe|object)element/i.test(element))
{
@@ -354,7 +354,7 @@
}
- if (!width || (width < this.min_width && !dont_force_min))
+ if (!width || (width < this.min_width))
{
width = this.min_width;
}
@@ -364,7 +364,7 @@
// Find the flash object height
LinternaMagica.prototype.extract_object_height =
-function(element, dont_force_min)
+function(element)
{
if (!/HTML(embed|iframe|object)element/i.test(element))
{
@@ -408,7 +408,7 @@
height = element.parentNode.offsetHeight;
}
- if (!height || (height<this.min_height && !dont_force_min))
+ if (!height || (height<this.min_height))
{
height = this.min_height;
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [linterna-magica-commit] [348] Force min height and width.,
Ivaylo Valkov <=