1. #1
    Sencha User
    Join Date
    Sep 2011
    Posts
    3
    Vote Rating
    0
    apk3005 is on a distinguished road

      0  

    Default Dynamic css styling

    Dynamic css styling


    am using a TabPabel and i've register a selection listerner on the TabItems

    what i want to do is to add a css style to the TabItem after it has been clicked but with using the addStyleName() oder setStyleName() method the underlying <div> of the TabItem, which is representing the content of the Tab, gets the new style name an not the <li>

    can anybody help me about this?

  2. #2
    Sencha - GXT Dev Team
    Join Date
    Feb 2009
    Location
    Minnesota
    Posts
    2,731
    Vote Rating
    90
    Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light

      0  

    Default


    Assuming you are trying to style the active tab indicator (not the tab contents themselves), you could write css for `li.x-tab-strip-active`. This way you need not add an additional class when the active tab changes. Note, however, that there is no div in that setup.

    If you want to style the contents of the now-active tab, you could just style all of the tab items, and only the visible one will be seen by the user (as the others are not visible).

  3. #3
    Sencha User
    Join Date
    Sep 2011
    Posts
    3
    Vote Rating
    0
    apk3005 is on a distinguished road

      0  

    Default


    thanks for your answer this is what im using now but what i need is something like a "was visitied/clicked"-flag which idicates that the tab was clicked at least once depending on this it should get an other look and so an other css class

    to make it more clear:
    i want to have a kind of timeline (arrows) where each tab can be clicked when there was something done in the tab before , before this all tabs are disabled, but i can select the second tab again to change something there when i'm allready on the fifth tab and this is the part where it gets tricky because with just having a straight forward navigation i can use the classes for disabled and enabled but with the possibility to jump back to another allready visited tab it looks very bad like in the picture below

    steps.jpg

    any idea about this?

  4. #4
    Sencha - GXT Dev Team
    Join Date
    Feb 2009
    Location
    Minnesota
    Posts
    2,731
    Vote Rating
    90
    Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light

      0  

    Default


    Couple of thoughts:

    Tabs are meant to be non-linear, you can move from any tab to any other easily - it sounds more like you are describing a wizard, where moving from one step to another often has some rules associated with it. The TabPanel hides all but one item using a CardLayout - this could be used to build a wizard , with some other widget to go forward/back and to indicate the current, completed, and future steps.

    That said, TabPanel fires a BeforeSelect event, allowing you to ask the TabPanel which TabItem is currently selected. One option (if you simply want to disable the tab) would be to call .setEnabled(false) on that soon-to-be blurred item, another would be to simply style the header (available via tabItem.getHeader()).

  5. #5
    Sencha User
    Join Date
    Sep 2011
    Posts
    3
    Vote Rating
    0
    apk3005 is on a distinguished road

      0  

    Default


    Thank you for your reply. the tabItem.getHeader() - method does exactly what i needed

Thread Participants: 1

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