List of usage examples for com.vaadin.ui Button Button
public Button(Resource icon, ClickListener listener)
From source file:com.esofthead.mycollab.module.project.view.ProjectBreadcrumb.java
License:Open Source License
public void gotoProblemRead(Problem problem) { this.select(0); this.addLink(new Button(AppContext.getMessage(BreadcrumbI18nEnum.PROBLEMS), new GotoProblemListListener())); this.setLinkEnabled(true, 1); this.addLink(generateBreadcrumbLink(problem.getIssuename())); AppContext.addFragment(ProjectLinkGenerator.generateProblemPreviewLink(project.getId(), problem.getId()), AppContext.getMessage(BreadcrumbI18nEnum.FRA_PROBLEM_READ, problem.getIssuename())); }
From source file:com.esofthead.mycollab.module.project.view.ProjectBreadcrumb.java
License:Open Source License
public void gotoProblemEdit(final Problem problem) { this.select(0); this.addLink(new Button(AppContext.getMessage(BreadcrumbI18nEnum.PROBLEMS), new GotoProblemListListener())); this.setLinkEnabled(true, 1); this.addLink(generateBreadcrumbLink(problem.getIssuename(), new Button.ClickListener() { private static final long serialVersionUID = 1L; @Override//from w ww . j a va2s . com public void buttonClick(ClickEvent event) { EventBusFactory.getInstance().post(new ProblemEvent.GotoRead(this, problem.getId())); } })); this.setLinkEnabled(true, 2); this.addLink(new Button(AppContext.getMessage(GenericI18Enum.BUTTON_EDIT))); AppContext.addFragment( "project/problem/edit/" + UrlEncodeDecoder.encode(project.getId() + "/" + problem.getId()), AppContext.getMessage(BreadcrumbI18nEnum.FRA_PROBLEM_EDIT, problem.getIssuename())); }
From source file:com.esofthead.mycollab.module.project.view.ProjectBreadcrumb.java
License:Open Source License
public void gotoProblemAdd() { this.select(0); this.addLink(new Button(AppContext.getMessage(BreadcrumbI18nEnum.PROBLEMS), new GotoProblemListListener())); this.setLinkEnabled(true, 1); this.addLink(new Button(AppContext.getMessage(GenericI18Enum.BUTTON_ADD))); AppContext.addFragment("project/problem/add/" + UrlEncodeDecoder.encode(project.getId()), AppContext.getMessage(BreadcrumbI18nEnum.FRA_PROBLEM_NEW)); }
From source file:com.esofthead.mycollab.module.project.view.ProjectBreadcrumb.java
License:Open Source License
public void gotoTaskListReorder() { this.select(0); this.addLink( new Button(AppContext.getMessage(BreadcrumbI18nEnum.TASKS), new GotoTaskAssignmentDashboard())); this.setLinkEnabled(true, 1); this.addLink(new Button(AppContext.getMessage(BreadcrumbI18nEnum.FRA_TASKGROUP_REORDER))); AppContext.addFragment("project/task/dashboard/reorder/" + UrlEncodeDecoder.encode(project.getId()), AppContext.getMessage(BreadcrumbI18nEnum.FRA_TASKGROUP_REORDER)); }
From source file:com.esofthead.mycollab.module.project.view.ProjectBreadcrumb.java
License:Open Source License
public void gotoTaskGroupAdd() { this.select(0); this.addLink( new Button(AppContext.getMessage(BreadcrumbI18nEnum.TASKS), new GotoTaskAssignmentDashboard())); this.setLinkEnabled(true, 1); this.addLink(new Button(AppContext.getMessage(BreadcrumbI18nEnum.FRA_TASKGROUP_NEW))); AppContext.addFragment("project/task/taskgroup/add/" + UrlEncodeDecoder.encode(project.getId()), AppContext.getMessage(BreadcrumbI18nEnum.FRA_TASKGROUP_NEW)); }
From source file:com.esofthead.mycollab.module.project.view.ProjectBreadcrumb.java
License:Open Source License
public void gotoTaskGroupRead(TaskList taskList) { this.select(0); this.addLink( new Button(AppContext.getMessage(BreadcrumbI18nEnum.TASKS), new GotoTaskAssignmentDashboard())); this.setLinkEnabled(true, 1); this.addLink(generateBreadcrumbLink( AppContext.getMessage(BreadcrumbI18nEnum.FRA_TASKGROUP_READ, taskList.getName()))); AppContext.addFragment(ProjectLinkGenerator.generateTaskGroupPreviewLink(project.getId(), taskList.getId()), AppContext.getMessage(BreadcrumbI18nEnum.FRA_TASKGROUP_READ, taskList.getName())); }
From source file:com.esofthead.mycollab.module.project.view.ProjectBreadcrumb.java
License:Open Source License
public void gotoTaskGroupEdit(final TaskList taskList) { this.select(0); this.addLink( new Button(AppContext.getMessage(BreadcrumbI18nEnum.TASKS), new GotoTaskAssignmentDashboard())); this.setLinkEnabled(true, 1); this.addLink(generateBreadcrumbLink( AppContext.getMessage(BreadcrumbI18nEnum.FRA_TASKGROUP_READ, taskList.getName()), new Button.ClickListener() { private static final long serialVersionUID = 1L; @Override/*from ww w . jav a 2 s . c o m*/ public void buttonClick(ClickEvent event) { EventBusFactory.getInstance().post(new TaskListEvent.GotoRead(this, taskList.getId())); } })); this.setLinkEnabled(true, 2); this.addLink(new Button(AppContext.getMessage(GenericI18Enum.BUTTON_EDIT))); AppContext.addFragment( "project/task/taskgroup/edit/" + UrlEncodeDecoder.encode(project.getId() + "/" + taskList.getId()), AppContext.getMessage(BreadcrumbI18nEnum.FRA_TASKGROUP_EDIT, taskList.getName())); }
From source file:com.esofthead.mycollab.module.project.view.ProjectBreadcrumb.java
License:Open Source License
public void gotoTaskAdd() { this.select(0); this.addLink( new Button(AppContext.getMessage(BreadcrumbI18nEnum.TASKS), new GotoTaskAssignmentDashboard())); this.setLinkEnabled(true, 1); this.addLink(new Button(AppContext.getMessage(BreadcrumbI18nEnum.FRA_TASK_NEW))); AppContext.addFragment("project/task/task/add/" + UrlEncodeDecoder.encode(project.getId()), AppContext.getMessage(BreadcrumbI18nEnum.FRA_TASK_NEW)); }
From source file:com.esofthead.mycollab.module.project.view.ProjectBreadcrumb.java
License:Open Source License
public void gotoTaskSearch() { this.select(0); this.addLink( new Button(AppContext.getMessage(BreadcrumbI18nEnum.TASKS), new GotoTaskAssignmentDashboard())); this.setLinkEnabled(true, 1); this.addLink(new Button("Task: Filter")); AppContext.addFragment("project/task/filter/" + UrlEncodeDecoder.encode(project.getId()), "Task: Filter"); }
From source file:com.esofthead.mycollab.module.project.view.ProjectBreadcrumb.java
License:Open Source License
public void gotoGanttView() { this.select(0); this.addLink( new Button(AppContext.getMessage(BreadcrumbI18nEnum.TASKS), new GotoTaskAssignmentDashboard())); this.setLinkEnabled(true, 1); this.addLink(new Button("Gantt chart")); AppContext.addFragment("project/task/gantt/" + UrlEncodeDecoder.encode(project.getId()), "Gantt chart"); }