4,10 → 4,10 |
* Coded by: Group 5, software practice summer 2003 |
* University of Bielefeld, Germany |
* |
* @version $Revision: 1.45 $ |
* @version $Revision: 1.46 $ |
* |
* Last modification: $Date: 2003/07/22 12:04:26 $ |
* $Id: UpdateView.java,v 1.45 2003/07/22 12:04:26 mdonner Exp $ |
* Last modification: $Date: 2003/07/22 13:10:35 $ |
* $Id: UpdateView.java,v 1.46 2003/07/22 13:10:35 mdonner Exp $ |
*/ |
|
package src.gui; |
46,7 → 46,7 |
* |
* @author Christian Stollenwerk |
* |
* @version $Revision: 1.45 $ Last modification: $Date: 2003/07/22 12:04:26 $ |
* @version $Revision: 1.46 $ Last modification: $Date: 2003/07/22 13:10:35 $ |
*/ |
public class UpdateView implements ActionListener, UpdateViewInterface, |
OurEventListener, TreeModelListener, TreeExpansionListener, TreeSelectionListener { |
86,16 → 86,19 |
expression.trim(); |
if(expression.length() == 0) { |
isFiltered = false; |
documentManagerInterface.setExpression(""); |
} |
else { |
isFiltered = true; |
doc = documentManagerInterface.getActualDocument(); |
nodeList = viewFilter.filter(doc, expression); |
documentManagerInterface.setExpression(expression); |
if(nodeList == null) { |
JOptionPane.showMessageDialog(gui.getRootPane(), |
"You entered an invalid XPath expression", |
"XPath not valid", |
JOptionPane.ERROR_MESSAGE); |
isFiltered = false; |
} |
} |
update(); |
116,6 → 119,12 |
else { |
dividerPosition = gui.getDivider(); |
gui.setTreeVisible(true); |
if(documentManagerInterface.getExpression() != "") { |
isFiltered = true; |
} |
else { |
isFiltered = false; |
} |
// checks if an XPath-expression is set |
if(isFiltered == true) { |
//DocumentImpl helpDoc = new DocumentImpl(); |