Package org.olat.core.util.i18n.ui

Source Code of org.olat.core.util.i18n.ui.TranslationToolMainController

/**
* OLAT - Online Learning and Training<br>
* http://www.olat.org
* <p>
* Licensed under the Apache License, Version 2.0 (the "License"); <br>
* you may not use this file except in compliance with the License.<br>
* You may obtain a copy of the License at
* <p>
* http://www.apache.org/licenses/LICENSE-2.0
* <p>
* Unless required by applicable law or agreed to in writing,<br>
* software distributed under the License is distributed on an "AS IS" BASIS, <br>
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. <br>
* See the License for the specific language governing permissions and <br>
* limitations under the License.
* <p>
* Copyright (c) frentix GmbH<br>
* http://www.frentix.com<br>
* <p>
*/

package org.olat.core.util.i18n.ui;

import org.olat.core.commons.fullWebApp.LayoutMain3ColsController;
import org.olat.core.gui.UserRequest;
import org.olat.core.gui.components.Component;
import org.olat.core.gui.control.Event;
import org.olat.core.gui.control.WindowControl;
import org.olat.core.gui.control.controller.MainLayoutBasicController;
import org.olat.core.gui.control.generic.breadcrumb.BreadCrumbController;

/**
* <h3>Description:</h3>
* <p>
* This controller serves as the main entry point of the translation tool
* controller. The workflow is intended to run in a separate window. The
* functionality allows to translate the system languages.
* <h3>
* Events thrown by this controller:</h3>
* <ul>
* <li>none</li>
* </ul>
* <p>
* Initial Date: 08.09.2008 <br>
*
* @author Florian Gnaegi, frentix GmbH, http://www.frentix.com
*/

class TranslationToolMainController extends MainLayoutBasicController {
  private LayoutMain3ColsController mainLayoutCtr;
  private BreadCrumbController breadCrumbLayoutCtr;
  private TranslationToolStartCrumbController startCtr;

  /**
   * Constructor to create the translation tool main view
   *
   * @param ureq
   * @param control
   * @param customizingMode true: edit overlay customization files and not
   *          language files; false: edit language files
   */
  public TranslationToolMainController(UserRequest ureq, WindowControl control, boolean customizingMode) {
    super(ureq, control);
    // Create bread crumb navigation
    breadCrumbLayoutCtr = new BreadCrumbController(ureq, control);
    listenTo(breadCrumbLayoutCtr);
    // Add translation tool start controller to bread crumb
    startCtr = new TranslationToolStartCrumbController(ureq, control, customizingMode);
    listenTo(startCtr);
    breadCrumbLayoutCtr.activateFirstCrumbController(startCtr);
    // Our view is generated by the main and the bread crumb layouer
    mainLayoutCtr = new LayoutMain3ColsController(ureq, getWindowControl(), null, null, breadCrumbLayoutCtr.getInitialComponent(), null);
    listenTo(mainLayoutCtr);
    putInitialPanel(mainLayoutCtr.getInitialComponent());
  }

  /*
   * (non-Javadoc)
   *
   * @see
   * org.olat.core.gui.control.DefaultController#event(org.olat.core.gui.UserRequest
   * , org.olat.core.gui.components.Component, org.olat.core.gui.control.Event)
   */
  @Override
  protected void event(UserRequest ureq, Component source, Event event) {
  // no events to catch
  }

  /*
   * (non-Javadoc)
   *
   * @see org.olat.core.gui.control.DefaultController#doDispose()
   */
  @Override
  protected void doDispose() {
  // controllers autodisposed by BasicController
  }
}
TOP

Related Classes of org.olat.core.util.i18n.ui.TranslationToolMainController

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.