Quantcast
Channel: SCN : All Content - All Communities
Viewing all articles
Browse latest Browse all 3184

OPA5 trigger IconTabBar - Select

$
0
0

Hi All,

 

I'm trying to trigger the Select event on an IconTabBar. I have tried a few options but nothing seems to trigger the associated event,

 

I have tried things like:

 

1. sap.ui.test.qunit.triggerKeydown(tab2, jQuery.sap.KeyCodes.SPACE);

2. control.setSelectedKey("selfInfo");

 

or even trying to put it all together,

 

iPressOnUpdate: function() {

     return this.waitFor({

       id: "idIconTabBar",

       viewName: "Detail",

       success: function(control) {

        control.setSelectedKey("selfInfo");

        var tab2 = control.getItems()[1].$();

        tab2.focus();

          sap.ui.test.qunit.triggerKeydown(tab2, jQuery.sap.KeyCodes.SPACE);

      },

            errorMessage: "Update not found in IconTabBar"

      });

     },

 

But in the end the best I can do is select the tab but the associated event is not fired. How can this be done?

 

I tried this  from stackoverflow but it did not work,

 

return this.waitFor({

  id: "mySecondTab-icon",

  viewName: sViewName,

  success: function (control) {

  control.$().trigger("saptouchend");

  },

  errorMessage: "Second IconTabFilter not found in IconTabBar"

});

 

Thanks,

Stuart


Viewing all articles
Browse latest Browse all 3184

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>