Lines 87-99
Link Here
|
87 |
} |
87 |
} |
88 |
}; |
88 |
}; |
89 |
|
89 |
|
90 |
// updates the find replace action if the document length is > 0 |
90 |
// updates the find replace action and the clear action if the document length is > 0 |
91 |
private ITextListener textListener = new ITextListener() { |
91 |
private ITextListener textListener = new ITextListener() { |
92 |
public void textChanged(TextEvent event) { |
92 |
public void textChanged(TextEvent event) { |
93 |
IUpdate findReplace = (IUpdate)fGlobalActions.get(ActionFactory.FIND.getId()); |
93 |
IUpdate findReplace = (IUpdate)fGlobalActions.get(ActionFactory.FIND.getId()); |
94 |
if (findReplace != null) { |
94 |
if (findReplace != null) { |
95 |
findReplace.update(); |
95 |
findReplace.update(); |
96 |
} |
96 |
} |
|
|
97 |
|
98 |
if (fClearOutputAction != null) { |
99 |
fClearOutputAction.setEnabled(fViewer.getDocument().getLength() > 0); |
100 |
} |
97 |
} |
101 |
} |
98 |
}; |
102 |
}; |
99 |
|
103 |
|