Results 1 to 8 of 8

Thread: Hiding search bar

  1. #1
    Join Date
    Aug 2011
    Posts
    9
    Rep Power
    4

    Default Hiding search bar

    Hi
    I am writing simple tab zimlet i found a way to hide the search bar this way :
    var shell = appCtxt.getShell();
    var arr = shell.getChildren();
    arr[9].setVisible(false);

    The problem is when i execute arr[9].setVisible(true); the bar dont show up immediately and the display on the new tab (e.g. Mail,Contacts e.t.c.) is messed-up.

    Any suggestions ?

    P.S. Basically what i need is manually calling a method which is refreshing current view before the new tab opens.

    Thanks in Advance.

  2. #2
    Join Date
    Aug 2011
    Posts
    9
    Rep Power
    4

    Default

    Thanks i found it.
    Note: appCtxt.getAppViewMgr().fitAll();

  3. #3
    Join Date
    May 2007
    Posts
    23
    Rep Power
    8

    Default

    Where did you enter these lines in the javascript?

  4. #4
    Join Date
    Aug 2011
    Posts
    9
    Rep Power
    4

    Default On the loading of zimlet

    On the loading of zimlet (dosn't matter which)
    Release 7.1.1_GA_3196.RHEL5_64_20110527011124 CentOS5_64 FOSS edition.

  5. #5
    Join Date
    May 2007
    Posts
    23
    Rep Power
    8

    Default

    It doesn't seem to be working. I am using zimbra network edition version 7

    Here is what I have:

    /**
    * Defines the Zimlet handler class.
    *
    */
    function com_zimbra_projects_HandlerObject() {
    }

    /**
    * Makes the Zimlet class a subclass of ZmZimletBase.
    *
    */
    com_zimbra_projects_HandlerObject.prototype = new ZmZimletBase();
    com_zimbra_projects_HandlerObject.prototype.constr uctor = com_zimbra_projects_HandlerObject;

    /**
    * This method gets called by the Zimlet framework when the zimlet loads.
    *
    */
    appCtxt.getAppViewMgr().fitAll();
    com_zimbra_projects_HandlerObject.prototype.init =
    function() {

    this._simpleAppName = this.createApp("Projects", "zimbraIcon", "Do More");

    };

    /**
    * This method gets called by the Zimlet framework each time the application is opened or closed.
    *
    * @param {String} appName the application name
    * @param {Boolean} active if true, the application status is open; otherwise, false
    */
    com_zimbra_projects_HandlerObject.prototype.appAct ive =
    function(appName, active) {

    switch (appName) {
    case this._simpleAppName: {

    var app = appCtxt.getApp(appName); // get access to ZmZimletApp




    break;
    }
    }

    // do something
    };

    /**
    * This method gets called by the Zimlet framework when the application is opened for the first time.
    *
    * @param {String} appName the application name
    */
    com_zimbra_projects_HandlerObject.prototype.appLau nch =
    function(appName) {

    switch (appName) {
    case this._simpleAppName: {
    // do something

    var app = appCtxt.getApp(appName); // get access to ZmZimletApp



    app.setContent("<iframe id=\"tabiframe-app\" name=\"tabiframe-app\" src=\"http://projects.essdack.org\" width=\"100%\" height=\"100%\" /></iframe>"); // write HTML to app

    break;
    }
    }

    };

  6. #6
    Join Date
    Aug 2011
    Posts
    9
    Rep Power
    4

    Default

    /**
    * Defines the Zimlet handler class.
    *
    */
    function com_zimbra_projects_HandlerObject() {
    }

    /**
    * Makes the Zimlet class a subclass of ZmZimletBase.
    *
    */
    com_zimbra_projects_HandlerObject.prototype = new ZmZimletBase();
    com_zimbra_projects_HandlerObject.prototype.constr uctor = com_zimbra_projects_HandlerObject;

    /**
    * This method gets called by the Zimlet framework when the zimlet loads.
    *
    */

    com_zimbra_projects_HandlerObject.prototype.init =
    function() {

    this._simpleAppName = this.createApp("Projects", "zimbraIcon", "Do More");
    /**
    * Hide search bar
    */
    var shell = appCtxt.getShell();
    var arr = shell.getChildren();
    arr[9].setVisible(false);
    appCtxt.getAppViewMgr().fitAll();

    };

    Should do the work.
    Release 7.1.1_GA_3196.RHEL5_64_20110527011124 CentOS5_64 FOSS edition.

  7. #7
    Join Date
    May 2007
    Posts
    23
    Rep Power
    8

    Default

    Well, I just misread your post. That worked, but what I really want to do is hide the area that is reserved for the zimlet toolbar. Do you know how to do that?

  8. #8
    Join Date
    Aug 2011
    Posts
    9
    Rep Power
    4

    Default

    I'm sure there is an undocumented method for this and i remember i've used it. Unfortunately i can't find it right now.If i find it i will sure let you know.
    Release 7.1.1_GA_3196.RHEL5_64_20110527011124 CentOS5_64 FOSS edition.

Similar Threads

  1. Search file contents in Briefcase
    By LexxTheFox in forum Administrators
    Replies: 5
    Last Post: 10-20-2011, 11:31 AM
  2. Hiding Resources from a Location Search?
    By Chewie71 in forum Administrators
    Replies: 2
    Last Post: 09-19-2011, 11:38 AM
  3. Replies: 0
    Last Post: 05-30-2011, 06:26 PM
  4. Enhance Zimbra search to search local files
    By krabina in forum Developers
    Replies: 0
    Last Post: 11-03-2010, 03:28 PM
  5. Search within search
    By zocs in forum Users
    Replies: 0
    Last Post: 12-24-2007, 02:09 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
  •