Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Ext GWT Premium Member
    Join Date
    Jul 2009
    Posts
    34
    Vote Rating
    0
    mnilson is on a distinguished road

      0  

    Lightbulb [FNR] PagingToolBar and PagingToolBarMessages

    [FNR] PagingToolBar and PagingToolBarMessages


    There is a minor bug in the PagingToolBar in regards to how it handles the PagingToolBarMessages. PagingToolBar exposes a public void setMessages(PagingToolBarMessages messages) method, but the messages are used in the constructor of the toolbar and there is effectively no way to override the default behaviour of the toolbar displaying 'Page'. This should be a fairly simple refactor and would be appreciated.

    thanks,
    Michael

  2. #2
    Ext GWT Premium Member
    Join Date
    May 2009
    Posts
    35
    Vote Rating
    0
    yafmbl is on a distinguished road

      0  

    Default


    Same issue exists with most of the widgets as well. (DatePicker, if needed to name one) There is no easy to override methods, which deals with translations. You have to prepare a translation file to override existing translations most of the time. There should have been an easier way to override the translations programatically.

  3. #3
    Ext GWT Premium Member
    Join Date
    Jul 2009
    Posts
    34
    Vote Rating
    0
    mnilson is on a distinguished road

      0  

    Default


    In this case we aren't changing it due to translation, it is because the word 'Page' doesn't make sense in the given context. We would still want the word 'Page' to be displayed on other forms in the app. IMHO the current design of the paging toolbar wouldn't prevent a quick refactoring that would make the widget more flexible while not breaking existing use of it. I am not familiar enough with the other widgets to comment on their refactorability.

    Mike

  4. #4
    Ext User
    Join Date
    Sep 2008
    Location
    Germany
    Posts
    961
    Vote Rating
    0
    Arno.Nyhm is on a distinguished road

      0  

    Default


    but this overwriting the translation file also not work :-(
    (copy XMessages_de.properties with the same structure to my project - this overwrites the messages only in Hosted Mode. the GWT Compiler ignore this :-( )
    This forum needs your help: you got hints from the community and now you have fixed your code? dont just reply with "now its fixed" or "i found the error"! please take the time to post also an detailed answer with the working code.

    GreaseMonkey Script for a GXT-only Forum: it hides ExtJs here: New Posts • Search Results • Advanced Search form • Category overview http://www.extjs.com/forum/showthrea...041#post410041

  5. #5
    Ext User
    Join Date
    Sep 2008
    Location
    Germany
    Posts
    961
    Vote Rating
    0
    Arno.Nyhm is on a distinguished road

      0  

    Default


    Quote Originally Posted by mnilson View Post
    In this case we aren't changing it due to translation, it is because the word 'Page' doesn't make sense in the given context. We would still want the word 'Page' to be displayed on other forms in the app.
    in this case you can hide only the word with css. make an additional css entry and then add this special style to the pagingtoolbar or grid.
    This forum needs your help: you got hints from the community and now you have fixed your code? dont just reply with "now its fixed" or "i found the error"! please take the time to post also an detailed answer with the working code.

    GreaseMonkey Script for a GXT-only Forum: it hides ExtJs here: New Posts • Search Results • Advanced Search form • Category overview http://www.extjs.com/forum/showthrea...041#post410041

  6. #6
    Ext User
    Join Date
    Oct 2009
    Posts
    6
    Vote Rating
    0
    wangying95599 is on a distinguished road

      0  

    Default


    Quote Originally Posted by Arno.Nyhm View Post
    in this case you can hide only the word with css. make an additional css entry and then add this special style to the pagingtoolbar or grid.
    Can you help me hide the word "Page", I'm not good at css, I don't know how to do it ,Thanks a lot

  7. #7
    Ext User
    Join Date
    Oct 2009
    Posts
    6
    Vote Rating
    0
    wangying95599 is on a distinguished road

      0  

    Default


    if I hide the text "Page" by css, the part of "of x" also hidden, I just hope "Page" is disappered .

  8. #8
    Sencha User robertlight's Avatar
    Join Date
    Nov 2009
    Location
    Boston area
    Posts
    19
    Vote Rating
    0
    robertlight is on a distinguished road

      0  

    Default overriding PagingToolBarMessages

    overriding PagingToolBarMessages


    Has there been a solution to this? It seems like a horrible gap in functionality....clearly the authors felt it was necessary and desirable to let the developer have control over these messages.

    There has to be a better way (or a bug fix).

    - Bob

  9. #9
    Software Architect
    Join Date
    Sep 2007
    Posts
    13,971
    Vote Rating
    132
    sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light

      0  

    Default


    I have this on the list for 2.2 and already a patch pending.

  10. #10
    Sencha User robertlight's Avatar
    Join Date
    Nov 2009
    Location
    Boston area
    Posts
    19
    Vote Rating
    0
    robertlight is on a distinguished road

      0  

    Default PagingToolBar and PagingToolBarMessages

    PagingToolBar and PagingToolBarMessages


    I've patched it in my world.... can you publish your patch...at least if I use your patch, then it will be closer (or the same) when 2.2 comes out.

    Thanks!

    -Bob

Similar Threads

  1. [FNR] Change the language of PagingToolBarMessages
    By Iron Bull in forum Ext GWT: Bugs (2.x)
    Replies: 3
    Last Post: 15 Jul 2010, 7:06 AM
  2. [FNR] ScaleProvider
    By petko.ivanov in forum Ext GWT: Bugs (2.x)
    Replies: 1
    Last Post: 15 Mar 2010, 2:08 PM
  3. How to declare grid with pagingtoolbar, without calling PagingToolbar constructor
    By grzegorz.borkowski in forum Ext 2.x: Help & Discussion
    Replies: 4
    Last Post: 9 Feb 2009, 5:57 AM
  4. Replies: 1
    Last Post: 20 Jun 2008, 7:05 AM

Thread Participants: 5