htmlBasedComponent.getTabIndex causes null pointer exception

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: Critical
    • 8.0.3
    • Affects Version/s: 8.0.3
    • Component/s: None
    • Security Level: Jimmy
    • None
    • None

      If a HtmlBasedComponent auxInfo are not empty, but tabIndex is not set, getTabIndex causes NPI.

      Reproduce with:

      <zk>
      	<textbox id="tb" width="500px"/>
      	<zscript>
      		System.out.println(tb.getTabindex());
      		System.out.println(tb.getTabindexInteger());
      	</zscript>
      </zk>
      
      	public int getTabindex() {
      		return _auxinf != null ? _auxinf.tabindex : 0;
      	}
      
      
      could be changed to:
      
      
      	public int getTabindex() {
      		return (_auxinf != null && _auxinf.tabindex != null) ? _auxinf.tabindex : 0;
      	}
      

            Assignee:
            wenninghsu
            Reporter:
            MDuchemin
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 30 minutes
                30m