1. #1
    Ext User
    Join Date
    May 2008
    Posts
    97
    Vote Rating
    0
    jraue is on a distinguished road

      0  

    Default [CLOSED] SplitToolItem only reacting to drop-down arrow part

    [CLOSED] SplitToolItem only reacting to drop-down arrow part


    Hi!

    When I use a SplitToolItem as in the following code, the created tool item only reacts to the right part with the arrow and shows the menu as intended. However, it never reacts to clicking on the left part.

    Is this a bug or just my mistake?

    Thanks,

    Joachim

    ***

    final SplitToolItem toolItem = new SplitToolItem();
    toolItem.setIconStyle("myStyle");
    toolItem.setText("");
    toolItem.setToolTip("foo");
    toolItem.setMenu(menu);
    toolItem.addListener(Events.Select, new Listener<ComponentEvent>() {
    public void handleEvent(final ComponentEvent be) {
    doNew(); // Never executed
    }
    });

  2. #2
    Ext GWT Premium Member gslender's Avatar
    Join Date
    Mar 2008
    Location
    Brisbane, Australia
    Posts
    1,572
    Vote Rating
    3
    gslender is on a distinguished road

      0  

    Default


    what left part, right part.... the explorer demo works ok - are you able to explain further what aspect of explorer is not working, or provide more code or a screenshot that explains?

  3. #3
    Sencha - GXT Dev Team darrellmeyer's Avatar
    Join Date
    May 2007
    Location
    Washington, DC
    Posts
    2,242
    Vote Rating
    2
    darrellmeyer is on a distinguished road

      0  

    Default


    This code works fine with beta 4:

    Code:
      public void onModuleLoad() {
        SplitToolItem toolItem = new SplitToolItem();
        toolItem.setText("Test");
        toolItem.setToolTip("foo");
        toolItem.addListener(Events.Select, new Listener<ToolBarEvent>() {
          public void handleEvent(ToolBarEvent be) {
            System.out.println("Bang Bang");
          }
        });
        RootPanel.get().add(toolItem);
      }
    If you still have problems, then post complete test code.

  4. #4
    Ext User
    Join Date
    May 2008
    Posts
    97
    Vote Rating
    0
    jraue is on a distinguished road

      0  

    Default


    Sorry for my lack of precision. With right part, I was referring to the arrow part of the split button that triggers the menu, with the left part, the rest (basically the area that says "Split Button" in the explorer demo "Toolbar - Menu".

    In the explorer demo, there is no action associated with the left part, this is why the issue cannot show itself there. Would actually be interesting to add a listener for Events.Select to the explorer demo (show a dialog or sth).

    Darell, thanks for the code. I am still on beta3, so ToolBarEvent needed to be changed with ButtonEvent, but then it runs. It was my mistake, sorry and thanks for clarifying!

    Cheers,
    Joachim

Thread Participants: 2

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi