mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
bug 65477
This commit is contained in:
parent
34bb8dd348
commit
6ceb2d0ee8
3 changed files with 17 additions and 0 deletions
|
@ -112,6 +112,8 @@ public abstract class FindAction extends SelectionParseAction {
|
|||
if( obj == null || !(obj instanceof ICElement ) ){
|
||||
operationNotAvailable();
|
||||
return;
|
||||
} else {
|
||||
clearStatusLine();
|
||||
}
|
||||
ICElement element = (ICElement) obj;
|
||||
|
||||
|
@ -152,6 +154,8 @@ public abstract class FindAction extends SelectionParseAction {
|
|||
if (node == null || !( node instanceof IASTNode )){
|
||||
operationNotAvailable();
|
||||
return;
|
||||
} else {
|
||||
clearStatusLine();
|
||||
}
|
||||
|
||||
CSearchQuery job = createSearchQuery(node);
|
||||
|
|
|
@ -187,6 +187,8 @@ public class OpenDeclarationsAction extends SelectionParseAction implements IUpd
|
|||
if( namedElement == null ){
|
||||
operationNotAvailable();
|
||||
return;
|
||||
} else {
|
||||
clearStatusLine();
|
||||
}
|
||||
|
||||
if( storage.getResource() != null )
|
||||
|
|
|
@ -130,6 +130,17 @@ public class SelectionParseAction extends Action {
|
|||
if( statusManager != null )
|
||||
statusManager.setErrorMessage(CSearchMessages.getString("CSearchOperation.operationUnavailable.message"));//$NON-NLS-1$
|
||||
}
|
||||
protected void clearStatusLine() {
|
||||
IStatusLineManager statusManager = null;
|
||||
if (fSite instanceof IViewSite){
|
||||
statusManager = ((IViewSite) fSite).getActionBars().getStatusLineManager();
|
||||
}
|
||||
else if (fSite instanceof IEditorSite){
|
||||
statusManager = ((IEditorSite) fSite).getActionBars().getStatusLineManager();
|
||||
}
|
||||
if( statusManager != null )
|
||||
statusManager.setErrorMessage( "" ); //$NON-NLS-1$
|
||||
}
|
||||
|
||||
//TODO: Change this to work with qualified identifiers
|
||||
public SelSearchNode getSelection( int fPos ) {
|
||||
|
|
Loading…
Add table
Reference in a new issue