]> git.argeo.org Git - gpl/argeo-slc.git/blobdiff - org.argeo.slc.webapp/src/main/webapp/argeo-ria-src/class/org/argeo/ria/components/ViewPane.js
Always replace old content by new one
[gpl/argeo-slc.git] / org.argeo.slc.webapp / src / main / webapp / argeo-ria-src / class / org / argeo / ria / components / ViewPane.js
index bc7c8daa0a82e8cb455a2edabbe06e3678660b9f..1baf6af9d24352f3280e2dd49cd261cd1bef3fee 100644 (file)
@@ -138,6 +138,9 @@ qx.Class.define("org.argeo.ria.components.ViewPane",
        },
        
        contentExists : function(iViewId){
+               if(this.getContent()){
+                       this.empty();
+               }
                return false;
        },
        
@@ -207,12 +210,13 @@ qx.Class.define("org.argeo.ria.components.ViewPane",
        },
        
        focus : function(){
+               if(this.hasFocus) return;
                this.setDecorator(new qx.ui.decoration.Single(1,"solid","#065fb2"));
-               qx.event.Timer.once(function(){
-                       this.fireEvent("changeSelection");
-               }, this, 200);
+               this.fireEvent("changeSelection");
+               this.hasFocus = true;
        }, 
        blur : function(){
+               this.hasFocus = false;
                this.setDecorator(new qx.ui.decoration.Single(1,"solid","#000"));
        }