Results 1 to 10 of 11

Thread: [FNR] IE6: Radio generated without name

Hybrid View

Previous Post Previous Post   Next Post Next Post
    Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Ext GWT Premium Member mariusz.pala's Avatar
    Join Date
    Jun 2008
    Location
    Poland
    Posts
    306

    Default [FNR] IE6: Radio generated without name

    Hi,

    in IE6 I have some Radio buttons with the same name but not in RadioGroup (because they are place in a werid way).
    But in IE6 the Radio is generated without "name" attribute which causes that every radio can be selected, not just one. See the screenshot:
    problem.png

    This is generated HTML from IE Dev Toolbar:

    HTML Code:
    <INPUT class=" x-form-radio" id="x-auto-814" style="LEFT: 0px; POSITION: relative; TOP: 1px" type="radio" CHECKED __eventBits="6144" value="null" />
    And this is the code:

    Code:
    		ContentPanel main = new ContentPanel();
    		main.setHeaderVisible(false);
    		main.setBodyBorder(false);
    		main.setBorders(false);
    		main.setStyleAttribute("margin", "5px");
    
    		FieldSet optionSet = new FieldSet();
    		optionSet.setHeading(CaraMessages.INSTANCE.taskNotificationDialogNotifyWhenTask());
    		optionSet.setLayout(new RowLayout(Orientation.HORIZONTAL));
    		optionSet.setWidth("100%");
    		optionSet.setHeight(130);
    
    		ContentPanel group1 = new ContentPanel();
    		group1.setHeaderVisible(false);
    		group1.setBodyBorder(false);
    		group1.setBorders(false);
    		FormLayout layout = new FormLayout();
    		layout.setHideLabels(true);
    		group1.setLayout(layout);
    
    		final Radio issueRadio = new Radio();
    		issueRadio.setName(RADIO_NAME);
    		issueRadio.setBoxLabel(CaraMessages.INSTANCE.taskNotificationDialogIssued());
    		group1.add(issueRadio);
    
    		final Radio completedRadio = new Radio();
    		completedRadio.setName(RADIO_NAME);
    		completedRadio.setBoxLabel(CaraMessages.INSTANCE.taskNotificationDialogCompleted());
    		group1.add(completedRadio);
    
    		final Radio rejectedRadio = new Radio();
    		rejectedRadio.setName(RADIO_NAME);
    		rejectedRadio.setBoxLabel(CaraMessages.INSTANCE.taskNotificationDialogRejected());
    		group1.add(rejectedRadio);
    
    		ContentPanel group2 = new ContentPanel();
    		group2.setHeaderVisible(false);
    		group2.setBodyBorder(false);
    		group2.setBorders(false);
    		layout = new FormLayout();
    		layout.setHideLabels(true);
    		group2.setLayout(layout);
    
    		final Radio startOverdueRadio = new Radio();
    		startOverdueRadio.setName(RADIO_NAME);
    		startOverdueRadio.setBoxLabel(CaraMessages.INSTANCE.taskNotificationDialogStartOverdue());
    		group2.add(startOverdueRadio, new FormData("96%"));
    
    		final Radio finishDueRadio = new Radio();
    		finishDueRadio.setName(RADIO_NAME);
    		finishDueRadio.setBoxLabel(CaraMessages.INSTANCE.taskNotificationDialogFinishDueIn());
    
    		final SpinnerField thresholdField = new SpinnerField();
    		thresholdField.setWidth(50);
    		thresholdField.setPropertyEditorType(Integer.class);
    		thresholdField.setMinValue(0);
    		thresholdField.setFormat(NumberFormat.getFormat("##0"));
    		thresholdField.setAllowDecimals(false);
    		// thresholdField.setValue(taskTemplate.getTargetDuration());
    		thresholdField.setFireChangeEventOnSetValue(true);
    
    		LabelField dayLabel = new LabelField(CaraMessages.INSTANCE.taskNotificationDialogDays());
    
    		MultiField<Field<?>> mf = new MultiField<Field<?>>("", finishDueRadio, thresholdField, dayLabel);
    		group2.add(mf, new FormData("96%"));
    
    		final Radio finishOverdueRadio = new Radio();
    		finishOverdueRadio.setName(RADIO_NAME);
    		finishOverdueRadio.setBoxLabel(CaraMessages.INSTANCE.taskNotificationDialogFinishOverdue());
    		group2.add(finishOverdueRadio, new FormData("96%"));
    
    		main.add(optionSet);
    
    		optionSet.add(group1, new RowData(0.5, 1));
    		optionSet.add(group2, new RowData(0.5, 1));
    
    		add(main);
    The weird thing is that the Explorer example works fine. Actually buttons inside RadioGroup seems to be fine. So what can be wrong?

  2. #2
    Ext GWT Premium Member mariusz.pala's Avatar
    Join Date
    Jun 2008
    Location
    Poland
    Posts
    306

    Default

    The fix I need in that case is to modify onRender method in CheckBox class:

    Replace
    Code:
      @Override
      protected void onRender(Element target, int index) {
        if (this instanceof Radio) {
          input = new El(DOM.createInputRadio(""));
        } else {
          input = new El(DOM.createInputCheck());
        }
    With:
    Code:
      @Override
      protected void onRender(Element target, int index) {
        if (this instanceof Radio) {
          input = new El(DOM.createInputRadio(name));
        } else {
          input = new El(DOM.createInputCheck());
        }
    Unfortunately I can't ovewrite the onRender method and just change this because some attributes are not visible. How I can make a workaround for that without modifying Ext GWT source?

  3. #3
    Sencha Premium Member
    Join Date
    Sep 2007
    Posts
    13,976

    Default

    This is a duplicate and we already work on a fix for this.

  4. #4
    Ext GWT Premium Member mariusz.pala's Avatar
    Join Date
    Jun 2008
    Location
    Poland
    Posts
    306

    Default

    This is really critical, can you help me somehow with that? I changed the code to
    Code:
    input = new El(DOM.createInputRadio(name));
    but the result is the same...

  5. #5
    Sencha Premium Member
    Join Date
    Sep 2007
    Posts
    13,976

    Default

    That change is not sufficient. I commited a change to SVN at revision 2296 which should fix this.

    Can you please validate this?

  6. #6
    Ext GWT Premium Member mariusz.pala's Avatar
    Join Date
    Jun 2008
    Location
    Poland
    Posts
    306

    Default

    Thanks, I will do that.

Similar Threads

  1. Replies: 10
    Last Post: 14 Oct 2010, 4:19 PM
  2. Replies: 4
    Last Post: 28 Apr 2010, 3:55 AM
  3. [FNR] Radio layout problem in Firefox
    By zdarsky in forum Ext GWT: Bugs (2.x)
    Replies: 2
    Last Post: 8 Mar 2010, 1:59 AM
  4. [FNR] [2.0.1] TabItem with icon bug on IE6
    By micgala in forum Ext GWT: Bugs (2.x)
    Replies: 2
    Last Post: 8 Dec 2009, 2:40 PM
  5. [FNR] [2.0.1] Fields Names getting lost on IE6/7
    By micgala in forum Ext GWT: Bugs (2.x)
    Replies: 9
    Last Post: 7 Oct 2009, 4:24 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •