Page 2 of 2 FirstFirst 12
Results 11 to 18 of 18

Thread: Main Toolbar

  1. #11
    grahamb's Avatar
    grahamb is offline Trained Alumni
    Join Date
    Apr 2008
    Location
    Vancouver, BC
    Posts
    54
    Rep Power
    7

    Default

    Thanks for that, rrao! It worked mostly as advertised; the button is added to the toolbar when the view changes.

    All is not well, however... the button is supposed to trigger a Dwt dialog. When I click the button added by onShowView, the dialog is never created; Firebug throws a "args[0] is undefined" error (Dwt.js line 1092 --- if (args.length > 1 || args[0]._eventMgr) { ) in response to
    var view = new DwtComposite(this.getShell());


    The button does still work normally in the view that was present at startup (e.g if the client starts in conversation view, it works in that view but not in traditional).

    Any help or insight you can provide would be most appreciated. I can post the entire code if it helps.

  2. #12
    rrao is offline Zimbra Employee
    Join Date
    Sep 2005
    Posts
    187
    Rep Power
    9

    Default

    These two are supposed to two different buttons so if you are using the same id, it might cause problem..
    for example:
    com_zimbra_discover.discover in the code is the id for that button, try using two different ids depending on the view..something like com_zimbra_discover.discoverConv and com_zimbra_discover.discoverTrad

    Code:
    		var btn = this._toolbar.createOp(
    			com_zimbra_discover.discover,
    		{
    			text	: ZmMsg.discoverlabel,
    			tooltip : ZmMsg.discovertip,
    			index   :indx,
    			image   : "dy-panelIcon"
    		}
    			);
    Bugzilla - Wiki - Downloads - Before posting... Search!

  3. #13
    grahamb's Avatar
    grahamb is offline Trained Alumni
    Join Date
    Apr 2008
    Location
    Vancouver, BC
    Posts
    54
    Rep Power
    7

    Default

    Nope -- still getting the same error. Here's a possible clue: I added a firebug console.log(this); right before I create the dialog with
    Code:
    var view = new DwtComposite(this.getShell());
    When the dialog works, firebug prints ca_sfu_icat_resend (the namespace for the zimlet) to the console for the value of this. When it doesn't work, it just prints undefined.

  4. #14
    rrao is offline Zimbra Employee
    Join Date
    Sep 2005
    Posts
    187
    Rep Power
    9

    Default

    ok upload or send me your zimlet to rrao@
    Bugzilla - Wiki - Downloads - Before posting... Search!

  5. #15
    gregor is offline Loyal Member
    Join Date
    Sep 2008
    Posts
    98
    Rep Power
    6

    Default

    can you upload the zimlet ^.^ thx

  6. #16
    grahamb's Avatar
    grahamb is offline Trained Alumni
    Join Date
    Apr 2008
    Location
    Vancouver, BC
    Posts
    54
    Rep Power
    7

    Default

    Quote Originally Posted by rrao View Post
    ok upload or send me your zimlet to rrao@
    Thanks! I just got back from a vacation, so I'll clean up the code a bit and email it to you.

  7. #17
    grahamb's Avatar
    grahamb is offline Trained Alumni
    Join Date
    Apr 2008
    Location
    Vancouver, BC
    Posts
    54
    Rep Power
    7

    Default

    Just a quick update -- rrao helped fix my problem and the button now functions properly on both toolbars.


    gregor: We may submit the zimlet to the gallery but I need to clear that with some higher-ups here first as it contains some 'not-written-here' code.

  8. #18
    tzevy is offline New Member
    Join Date
    Jan 2011
    Posts
    4
    Rep Power
    4

    Default

    If the Mail tab has ZmId.VIEW_CONVLIST what's the Address Book ZmId ?

Page 2 of 2 FirstFirst 12

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. A Zimbra Toolbar?
    By jholder in forum Users
    Replies: 29
    Last Post: 03-03-2011, 01:51 AM
  2. Zimbra Address Book Toolbar Button
    By jonnybravo in forum Zimlets
    Replies: 0
    Last Post: 05-28-2008, 09:31 AM
  3. How can i add buttons to the compose toolbar?
    By MyMoon in forum Developers
    Replies: 1
    Last Post: 10-05-2007, 08:08 AM
  4. [SOLVED] Remove main domain!
    By zibra in forum Administrators
    Replies: 11
    Last Post: 09-27-2007, 08:50 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •