/* ************************************************************************

   qooxdoo - the new era of web development

   http://qooxdoo.org

   Copyright:
     2004-2011 1&1 Internet AG, Germany, http://www.1und1.de

   License:
     LGPL: http://www.gnu.org/licenses/lgpl.html
     EPL: http://www.eclipse.org/org/documents/epl-v10.php
     See the LICENSE file in the project's top-level directory for details.

   Authors:
     * Thomas Herchenroeder (thron7)

************************************************************************ */

/**
 * Slightly extended form of a @{qx.ui.basic.Label}, to include a version/
 * revision string of qooxdoo.
 */
qx.Class.define("qxc.ui.versionlabel.VersionLabel",
{
  extend : qx.ui.basic.Label,

  construct : function(value)
  {
    var labeltext;
    if (!value) {
      labeltext = "qooxdoo";
    } else {
      labeltext = value;
    }

    var versstring = qx.core.Environment.get("qx.revision") ? qx.core.Environment.get("qx.revision") :
      qx.core.Environment.get("qx.version");
    labeltext += " " + versstring;
    this.base(arguments, labeltext);
  }
});
