1 /**********************************************************************
2 * Copyright (c) 2011 Ericsson
4 * All rights reserved. This program and the accompanying materials are
5 * made available under the terms of the Eclipse Public License v1.0 which
6 * accompanies this distribution, and is available at
7 * http://www.eclipse.org/legal/epl-v10.html
10 * Bernd Hufmann - Initial API and implementation
11 **********************************************************************/
12 package org
.eclipse
.linuxtools
.tmf
.ui
.views
.uml2sd
.handlers
;
14 import org
.eclipse
.jface
.action
.Action
;
15 import org
.eclipse
.linuxtools
.internal
.tmf
.ui
.ITmfImageConstants
;
16 import org
.eclipse
.linuxtools
.internal
.tmf
.ui
.TmfUiPlugin
;
17 import org
.eclipse
.linuxtools
.tmf
.ui
.views
.uml2sd
.SDView
;
18 import org
.eclipse
.linuxtools
.tmf
.ui
.views
.uml2sd
.util
.SDMessages
;
21 * Moves the focus on the first page in the sequence diagram view.
23 public class FirstPage
extends Action
{
25 // ------------------------------------------------------------------------
27 // ------------------------------------------------------------------------
28 public static final String ID
= "org.eclipse.linuxtools.tmf.ui.views.uml2sd.handlers.firstpage"; //$NON-NLS-1$
30 protected SDView fView
= null;
32 // ------------------------------------------------------------------------
34 // ------------------------------------------------------------------------
35 public FirstPage(SDView theView
) {
38 setText(SDMessages
._139
);
39 setToolTipText(SDMessages
._140
);
41 setImageDescriptor(TmfUiPlugin
.getDefault().getImageDescripterFromPath(ITmfImageConstants
.IMG_UI_FIRST_PAGE
));
44 // ------------------------------------------------------------------------
46 // ------------------------------------------------------------------------
49 * @see org.eclipse.jface.action.Action#run()
53 if ((fView
== null) || (fView
.getSDWidget()) == null) {
56 if (fView
.getSDPagingProvider() != null) {
57 fView
.getSDPagingProvider().firstPage();
59 fView
.updateCoolBar();
60 fView
.getSDWidget().redraw();
This page took 0.042257 seconds and 6 git commands to generate.