Gridarta Editor
FindAgain.java
Go to the documentation of this file.
1 /*
2  * Gridarta MMORPG map editor for Crossfire, Daimonin and similar games.
3  * Copyright (C) 2000-2023 The Gridarta Developers.
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License along
16  * with this program; if not, write to the Free Software Foundation, Inc.,
17  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18  */
19 
20 package net.sf.gridarta.textedit.textarea.actions;
21 
22 import java.awt.event.ActionEvent;
23 import java.awt.event.ActionListener;
25 import org.jetbrains.annotations.NotNull;
26 
31 public class FindAgain implements ActionListener {
32 
36  @NotNull
37  private final Find find;
38 
42  @NotNull
43  private final Replace replace;
44 
49 
55  public FindAgain(@NotNull final Find find, @NotNull final Replace replace) {
56  this.find = find;
57  this.replace = replace;
58  }
59 
60  @Override
61  public void actionPerformed(@NotNull final ActionEvent e) {
62  switch (type) {
63  case NONE:
64  break;
65 
66  case FIND:
68  break;
69 
70  case REPLACE:
72  break;
73  }
74  }
75 
80  public void setType(@NotNull final FindType type) {
81  this.type = type;
82  }
83 
84 }
net.sf.gridarta.textedit.textarea.actions.FindType.NONE
NONE
Definition: FindType.java:31
net.sf.gridarta.textedit.textarea
net.sf.gridarta.textedit.textarea.actions.FindAgain.setType
void setType(@NotNull final FindType type)
Definition: FindAgain.java:80
net.sf.gridarta
net.sf.gridarta.textedit.textarea.actions.FindAgain.replace
final Replace replace
Definition: FindAgain.java:43
net.sf.gridarta.textedit.textarea.InputHandler.getTextArea
static JEditTextArea getTextArea(final EventObject evt)
Definition: InputHandler.java:144
net.sf
net.sf.gridarta.textedit.textarea.actions.Replace.replace
boolean replace(@NotNull final JEditTextArea textArea)
Definition: Replace.java:91
net.sf.gridarta.textedit
net.sf.gridarta.textedit.textarea.actions.Find
Definition: Find.java:37
net
net.sf.gridarta.textedit.textarea.actions.FindAgain.type
FindType type
Definition: FindAgain.java:48
net.sf.gridarta.textedit.textarea.actions.FindAgain.actionPerformed
void actionPerformed(@NotNull final ActionEvent e)
Definition: FindAgain.java:61
net.sf.gridarta.textedit.textarea.actions.Replace
Definition: Replace.java:50
net.sf.gridarta.textedit.textarea.actions.FindAgain.find
final Find find
Definition: FindAgain.java:37
net.sf.gridarta.textedit.textarea.actions.Find.find
void find(@NotNull final JEditTextArea textArea)
Definition: Find.java:67
net.sf.gridarta.textedit.textarea.actions.FindAgain.FindAgain
FindAgain(@NotNull final Find find, @NotNull final Replace replace)
Definition: FindAgain.java:55
net.sf.gridarta.textedit.textarea.actions.FindAgain
Definition: FindAgain.java:31
net.sf.gridarta.textedit.textarea.InputHandler
Definition: InputHandler.java:36
net.sf.gridarta.textedit.textarea.actions.FindType
Definition: FindType.java:26