← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 11084: (DV, PT) Misc gui fixes.

 

Merge authors:
  Jan Henrik Øverland (janhenrik-overland)
------------------------------------------------------------
revno: 11084 [merge]
committer: Jan Henrik Overland <janhenrik.overland@xxxxxxxxx>
branch nick: dhis2
timestamp: Wed 2013-05-29 17:13:53 +0200
message:
  (DV, PT) Misc gui fixes.
modified:
  dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/app.js
  dhis-2/dhis-web/dhis-web-visualizer/src/main/resources/org/hisp/dhis/visualizer/i18n_module.properties
  dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/app.js
  dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/core.js


--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk

Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/app.js'
--- dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/app.js	2013-05-29 14:14:12 +0000
+++ dhis-2/dhis-web/dhis-web-pivot/src/main/webapp/dhis-web-pivot/app/scripts/app.js	2013-05-29 14:36:37 +0000
@@ -1934,6 +1934,7 @@
 				width: 500,
 				bodyStyle: 'padding:5px 5px 3px; background-color:#fff',
 				resizable: true,
+				destroyOnBlur: true,
 				modal: true,
 				items: [
 					textArea,
@@ -1954,6 +1955,10 @@
 						pt.util.window.setAnchorPosition(w, pt.viewport.interpretationButton);
 
 						document.body.oncontextmenu = true;
+
+						if (!w.hasDestroyOnBlurHandler) {
+							pt.util.window.addDestroyOnBlurHandler(w);
+						}
 					},
 					hide: function() {
 						document.body.oncontextmenu = function(){return false;};

=== modified file 'dhis-2/dhis-web/dhis-web-visualizer/src/main/resources/org/hisp/dhis/visualizer/i18n_module.properties'
--- dhis-2/dhis-web/dhis-web-visualizer/src/main/resources/org/hisp/dhis/visualizer/i18n_module.properties	2013-05-29 14:14:12 +0000
+++ dhis-2/dhis-web/dhis-web-visualizer/src/main/resources/org/hisp/dhis/visualizer/i18n_module.properties	2013-05-29 15:03:05 +0000
@@ -194,4 +194,4 @@
 detailed_data_elements_cannot_be_specified_as_filter=Detailed data elements cannot be specified as filter
 plain_data_sources=Plain data source
 graphics=Graphics
-write_your_interpretation=Ecrire votre interpr\u00E9tation
\ No newline at end of file
+write_your_interpretation=Write a comment, question or interpretation
\ No newline at end of file

=== modified file 'dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/app.js'
--- dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/app.js	2013-05-29 13:34:16 +0000
+++ dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/app.js	2013-05-29 15:03:05 +0000
@@ -853,11 +853,10 @@
 		dv.viewport.hideTitle = hideTitle;
 
 		title = Ext.create('Ext.form.field.Text', {
-			//cls: 'dv-textfield-alt1',
 			style: 'margin-bottom:2px; margin-left:2px',
 			width: 310,
 			fieldLabel: DV.i18n.chart_title,
-			fieldLabel: 'Chart title',
+			labelStyle: 'color:#333',
 			labelWidth: 123,
 			maxLength: 100,
 			enforceMaxLength: true,
@@ -868,10 +867,10 @@
 		dv.viewport.title = title;
 
 		domainAxisTitle = Ext.create('Ext.form.field.Text', {
-			//cls: 'dv-textfield-alt1',
 			style: 'margin-bottom:2px; margin-left:2px',
 			width: 310,
 			fieldLabel: DV.i18n.domain_axis_label,
+			labelStyle: 'color:#333',
 			labelWidth: 123,
 			maxLength: 100,
 			enforceMaxLength: true
@@ -879,10 +878,10 @@
 		dv.viewport.domainAxisTitle = domainAxisTitle;
 
 		rangeAxisTitle = Ext.create('Ext.form.field.Text', {
-			//cls: 'dv-textfield-alt1',
 			style: 'margin-bottom:0; margin-left:2px',
 			width: 310,
 			fieldLabel: DV.i18n.range_axis_label,
+			labelStyle: 'color:#333',
 			labelWidth: 123,
 			maxLength: 100,
 			enforceMaxLength: true
@@ -901,7 +900,7 @@
 					bodyStyle: 'border:0 none',
 					items: [
 						{
-							bodyStyle: 'border:0 none; padding-top:3px; padding-left:2px; margin-right:5px',
+							bodyStyle: 'border:0 none; padding-top:3px; padding-left:2px; margin-right:5px; color:#333',
 							width: 130,
 							html: 'Target value / title:'
 						},
@@ -915,7 +914,7 @@
 					bodyStyle: 'border:0 none',
 					items: [
 						{
-							bodyStyle: 'border:0 none; padding-top:3px; padding-left:2px; margin-right:5px',
+							bodyStyle: 'border:0 none; padding-top:3px; padding-left:2px; margin-right:5px; color:#333',
 							width: 130,
 							html: 'Base value / title:'
 						},
@@ -1938,6 +1937,7 @@
 				bodyStyle: 'padding:5px 5px 3px; background-color:#fff',
 				resizable: true,
 				modal: true,
+				destroyOnBlur: true,
 				items: [
 					textArea,
 					linkPanel
@@ -1957,6 +1957,10 @@
 						dv.util.window.setAnchorPosition(w, dv.viewport.interpretationButton);
 
 						document.body.oncontextmenu = true;
+
+						if (!w.hasDestroyOnBlurHandler) {
+							dv.util.window.addDestroyOnBlurHandler(w);
+						}
 					},
 					hide: function() {
 						document.body.oncontextmenu = function(){return false;};

=== modified file 'dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/core.js'
--- dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/core.js	2013-05-29 13:34:16 +0000
+++ dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/core.js	2013-05-29 14:49:31 +0000
@@ -1649,6 +1649,7 @@
 				chart.legend.position = 'right';
 				chart.legend.isVertical = true;
 				chart.insetPadding = 20;
+				chart.padding = '20 0 20 20';
 				chart.shadow = true;
 
 				return chart;
@@ -1747,9 +1748,9 @@
 						layout = dv.api.layout.Layout(layoutConfig);
 
 					if (layout) {
-						layout.id = layoutConfig.id;
-						layout.name = layoutConfig.name;
 						dv.favorite = Ext.clone(layout);
+						dv.favorite.id = layoutConfig.id;
+						dv.favorite.name = layoutConfig.name;
 
 						dv.viewport.setFavorite(layout);
 					}