[Lada-commits] [PATCH] Added some CSS to make distinction between active and inactice windows more simple for the user
Wald Commits
scm-commit at wald.intevation.org
Tue Apr 7 17:17:16 CEST 2015
# HG changeset patch
# User Dustin Demuth <dustin at intevation.de>
# Date 1428419819 -7200
# Node ID 6f6d2df0013013a5fd08c1121442cc62b649ee35
# Parent 2ad36c8db968f21252cb01b216fe2b38ab97032d
Added some CSS to make distinction between active and inactice windows more simple for the user
diff -r 2ad36c8db968 -r 6f6d2df00130 app/view/window/MessungCreate.js
--- a/app/view/window/MessungCreate.js Fri Mar 27 15:54:43 2015 +0100
+++ b/app/view/window/MessungCreate.js Tue Apr 07 17:16:59 2015 +0200
@@ -36,6 +36,16 @@
}];
this.width = 700;
+ // add listeners to change the window appearence when it becomes inactive
+ this.on({
+ activate: function(){
+ this.getEl().removeCls('window-inactive');
+ },
+ deactivate: function(){
+ this.getEl().addCls('window-inactive');
+ }
+ });
+
this.items = [{
border: 0,
autoScroll: true,
diff -r 2ad36c8db968 -r 6f6d2df00130 app/view/window/MessungEdit.js
--- a/app/view/window/MessungEdit.js Fri Mar 27 15:54:43 2015 +0100
+++ b/app/view/window/MessungEdit.js Tue Apr 07 17:16:59 2015 +0200
@@ -49,6 +49,17 @@
scope: this,
handler: this.close
}];
+
+ // add listeners to change the window appearence when it becomes inactive
+ this.on({
+ activate: function(){
+ this.getEl().removeCls('window-inactive');
+ },
+ deactivate: function(){
+ this.getEl().addCls('window-inactive');
+ }
+ });
+
this.width = 700;
this.height = Ext.getBody().getViewSize().height - 30;
diff -r 2ad36c8db968 -r 6f6d2df00130 app/view/window/OrtCreate.js
--- a/app/view/window/OrtCreate.js Fri Mar 27 15:54:43 2015 +0100
+++ b/app/view/window/OrtCreate.js Tue Apr 07 17:16:59 2015 +0200
@@ -39,6 +39,16 @@
this.height = 515;
this.bodyStyle = {background: '#fff'};
+ // add listeners to change the window appearence when it becomes inactive
+ this.on({
+ activate: function(){
+ this.getEl().removeCls('window-inactive');
+ },
+ deactivate: function(){
+ this.getEl().addCls('window-inactive');
+ }
+ });
+
this.items = [{
region: 'west',
border: 0,
diff -r 2ad36c8db968 -r 6f6d2df00130 app/view/window/OrtEdit.js
--- a/app/view/window/OrtEdit.js Fri Mar 27 15:54:43 2015 +0100
+++ b/app/view/window/OrtEdit.js Tue Apr 07 17:16:59 2015 +0200
@@ -51,6 +51,16 @@
this.height = 515;
this.bodyStyle = {background: '#fff'};
+ // add listeners to change the window appearence when it becomes inactive
+ this.on({
+ activate: function(){
+ this.getEl().removeCls('window-inactive');
+ },
+ deactivate: function(){
+ this.getEl().addCls('window-inactive');
+ }
+ });
+
this.items = [{
region: 'west',
border: 0,
diff -r 2ad36c8db968 -r 6f6d2df00130 app/view/window/ProbeCreate.js
--- a/app/view/window/ProbeCreate.js Fri Mar 27 15:54:43 2015 +0100
+++ b/app/view/window/ProbeCreate.js Tue Apr 07 17:16:59 2015 +0200
@@ -33,6 +33,17 @@
scope: this,
handler: this.close
}];
+
+ // add listeners to change the window appearence when it becomes inactive
+ this.on({
+ activate: function(){
+ this.getEl().removeCls('window-inactive');
+ },
+ deactivate: function(){
+ this.getEl().addCls('window-inactive');
+ }
+ });
+
this.width = 700;
// InitialConfig is the config object passed to the constructor on
// creation of this window. We need to pass it throuh to the form as
diff -r 2ad36c8db968 -r 6f6d2df00130 app/view/window/ProbeEdit.js
--- a/app/view/window/ProbeEdit.js Fri Mar 27 15:54:43 2015 +0100
+++ b/app/view/window/ProbeEdit.js Tue Apr 07 17:16:59 2015 +0200
@@ -30,7 +30,6 @@
record: null,
-
initComponent: function() {
if (this.record === null) {
Ext.Msg.alert('Keine valide Probe ausgewählt!');
@@ -45,6 +44,17 @@
handler: this.close
}];
this.width = 700;
+
+ // add listeners to change the window appearence when it becomes inactive
+ this.on({
+ activate: function(){
+ this.getEl().removeCls('window-inactive');
+ },
+ deactivate: function(){
+ this.getEl().addCls('window-inactive');
+ }
+ });
+
this.height = Ext.getBody().getViewSize().height - 30;
// InitialConfig is the config object passed to the constructor on
// creation of this window. We need to pass it throuh to the form as
diff -r 2ad36c8db968 -r 6f6d2df00130 resources/css/lada.css
--- a/resources/css/lada.css Fri Mar 27 15:54:43 2015 +0100
+++ b/resources/css/lada.css Tue Apr 07 17:16:59 2015 +0200
@@ -13,3 +13,5 @@
background-position: bottom;
border-color: #FF0000;
}
+
+.window-inactive .x-window-header-text {color: #a9a9a9;}
More information about the Lada-commits
mailing list