Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    #31
    I'm not having the same luck as MarcusZ - I still get the height issue mentioned below when running with SmartClient 8.2 01-25-2013

    Originally posted by acarur01 View Post
    SmartClient 8.2p 01-23-2013 build

    While trying to reproduce another FF18 issue, I was able to reproduce the last issue I mentioned. I ran this testcase with the datasource in isomorphic/system/reference/SmartClient_Explorer.html#nodeTitles

    If you run the testcase, you'll see that 'innerLayout' height is expanded beyond what the dynamic form takes up.

    Code:
    isc.ClassFactory.defineClass("CwMenuItem", "CanvasItem");
    
    isc.CwMenuItem.addProperties({
        init:function () {
            var canvasProperties = {
                    ID: this.widgetID,
                    title: this.menuTitle,
                    name: this.name,
                    canFocus: this.canFocus,
                    shouldSaveValue: false,
                    $cwname: this.$cwname,
                    showDown: this.showDown,
                    showFocused: this.showFocused,
                    showEmptyMessage: false,
                    showRollOver: this.showRollOver,
                    labelVar: this.labelVar,
                    iconVar: this.iconVar,
                    iconWidth: this.iconWidth,
                    iconHeight: this.iconHeight,
                    align: this.menuAlign,
                    showMenuButtonImage: this.showMenuButtonImage,
                    showMenuBelow: true,
                    $cwmethod: this.$cwmethod,
                    click: this.cwClick,
                    auditor: this.auditor,
                    menu: this.menu,
                    prompt: this.prompt,
                    form: this.form,
                    visibility: this.visibility,
                    $cwValidate: this.$cwValidate,
                    hide: function(){
                        this.parentElement.hideItem(this.name);
    //                    this.Super("hide", null);
                    }
                };
            
            if (this.width != null)
                canvasProperties.width = this.width;
            if (this.height != null)
                canvasProperties.height = this.height;
            if (this.tabIndex == -1)
                canvasProperties.tabIndex = -1;
            if (this.accessKey != null)
                canvasProperties.accessKey = this.accessKey;
            if (this.hiliteAccessKey != null)
                canvasProperties.hiliteAccessKey = this.hiliteAccessKey;
            if (this.keyTitle != null)
                canvasProperties.keyTitle = this.keyTitle;
            if (this.autoFit != null) {
                canvasProperties.autoFit = this.autoFit;
                if (this.autoFit == true)
                  canvasProperties.overflow = "visible";
            }
            if (this.iconOnRight != null)
                canvasProperties.iconOnRight = this.iconOnRight;
            if (this.hoverStyle != null)
                canvasProperties.hoverStyle = this.hoverStyle;
            if (this.hoverWidth != null)
                canvasProperties.hoverWidth = this.hoverWidth;
            if (this.customStyle != null)
                canvasProperties.customStyle = this.customStyle;
            if (this.baseStyle != null)
                canvasProperties.baseStyle = this.baseStyle;
            
            this.canvas = isc.MenuButton.create(canvasProperties);
            
            return this.Super("init", arguments);
        }
    });
    
    isc.ClassFactory.defineClass("CwDynamicFormExtend", "DynamicForm");
    
    isc.CwDynamicFormExtend.addProperties({
    	setItems: function(itemList){
    		if(this.$cwCellBorderStyle!=null){
    			var i = 0;
    			var length = itemList.length;
    			
    			for(i=0;i<length;i++){
    				var currentField =  itemList.get(i);
    				var currentCellStyle = currentField.cellStyle;
    				if(currentCellStyle=="formCell" || currentCellStyle == null){
    					currentField.cellStyle =  this.$cwCellBorderStyle;
    				}
    			}
    		}
    		this.Super("setItems", [itemList]);
    	},
    	
        
        showContextMenu: function() {
        	var item = this.getFocusItem();
    		if (item != null && item.cwDisablePaste) 
    			return false;
    		return this.Super("showContextMenu", arguments);
        },
        
    	titleSuffix:"&nbsp;",
    	rightTitlePrefix:"&nbsp;",
    	requiredTitleSuffix: "*</B>",
    	requiredRightTitleSuffix: "*</B>",
    	requiredRightTitlePrefix: "<B> "
    });
    
    
    
    
    
    isc.VLayout.create({
    	ID:"outerLayout",
    	autoDraw: true,
    	height: "100%",
    	members:[]
    })
    
    isc.Button.create({
    left: 500,title: "create and show",
    click: function(){
    
    isc.TreeGrid.create({
        ID: "employeeTree",
        width: 500,
        height: 400,
        dataSource: "employees",
        autoFetchData:true,
        nodeIcon:"icons/16/person.png",
        folderIcon:"icons/16/person.png",
        showOpenIcons:false,
        showDropIcons:false,
        closedIconSuffix:"",
        fields: [
            {name: "Name", formatCellValue: "record.Job+':&nbsp;'+value"}
        ]
    });
    
    isc.VLayout.create({
    ID:"innerLayout",
    members:[
    	isc.CwDynamicFormExtend.create({
    		ID:"menuForm", 
    		fields: [
    		{_constructor:"CwMenuItem", title:"Hide Menu", name: "hideMenu"}
    		]
    	})
    ]
    });
    	outerLayout.addMember(innerLayout);
    	outerLayout.addMember(employeeTree);
    	
    	
    }
    })

    Comment


      #32
      Hi All
      We have a developer looking at the too-tall layout issues described in posts #27 and #31 (and the canvasItem.hide() problem which is presumably related, from post #28).

      We also have a developer working on resolving the problems with drop-shadows rendering oddly (showing gaps within the shadows).

      At this stage, this thread is starting to become unwieldy. We will continue to track those issues on this thread, but for any new Firefox-18 specific issues people encounter, we ask that you start a new thread.

      Regards
      Isomorphic Software
      Last edited by Isomorphic; 25 Jan 2013, 10:16.

      Comment


        #33
        Having done some investigation into the issue described in #27 and #31, it looks like things are behaving as expected for us with the latest nightly build.

        The inner layout is indeed sizing to be taller than the DynamicForm, but this is a result of the VLayout's standard behavior of expanding components to fill the available space unless they auto-fit (see layout.vPolicy). Specifying an explicit size (even a small size, which the form then overflows) will resolve this.

        We're attaching a screenshot showing the appearance we get with the unmodified test case as a sanity check to be sure we're seeing the same behavior

        Regards
        Isomorphic Software
        Attached Files

        Comment


          #34
          On this:
          I'm also having issues with my custom menu canvas item - whenever I call hide() on it, the tree refuses to draw properly. This is only broken in FF18 and unfortunately I am unable to reproduce as a standalone as of yet.
          We don't see any problems showing and hiding the custom menu item in the standalone test case you posted. Probably best to work on getting a standalone test case for this, and creating a new thread for that issue

          Regards
          Isomorphic Software

          Comment


            #35
            Hi,

            I've got the same problem.
            When a CanvasItem is not visible previous height problem is back.

            Here is a standalone test case:
            Code:
            DynamicForm form = new DynamicForm();
            form.setBorder("1px solid red");
            
            MyCanvasItem test1 = new MyCanvasItem("test1");
            		
            MyCanvasItem test2 = new MyCanvasItem("test2");
            test2.setVisible(false);
            		
            form.setFields(
            	test1,
            	test2
            );
            
            public class MyCanvasItem extends CanvasItem {
            	public MyCanvasItem(String name) {
            		super(name);
            			
            		setInitHandler(new FormItemInitHandler() {
            			public void onInit(FormItem item) {
            				Label label = new Label("test");
            				setCanvas(label);
            			}
            		});
            	}
            }
            Hope that help.

            Comment

            Working...
            X