Search in sources :

Example 31 with BasePanel

use of org.jabref.gui.BasePanel in project jabref by JabRef.

the class GlobalSearchBar method informUserAboutInvalidSearchQuery.

private void informUserAboutInvalidSearchQuery() {
    searchField.setBackground(NO_RESULTS_COLOR);
    searchQueryHighlightObservable.reset();
    BasePanel currentBasePanel = frame.getCurrentBasePanel();
    currentBasePanel.getMainTable().getTableModel().updateSearchState(MainTableDataModel.DisplayOption.DISABLED);
    searchIcon.setIcon(IconTheme.JabRefIcon.SEARCH.getSmallIcon().createWithNewColor(NO_RESULTS_COLOR));
    String illegalSearch = Localization.lang("Search failed: illegal search expression");
    searchIcon.setToolTipText(illegalSearch);
    currentResults.setText(illegalSearch);
    openCurrentResultsInDialog.setEnabled(false);
}
Also used : BasePanel(org.jabref.gui.BasePanel)

Aggregations

BasePanel (org.jabref.gui.BasePanel)31 BibEntry (org.jabref.model.entry.BibEntry)14 Path (java.nio.file.Path)4 NamedCompound (org.jabref.gui.undo.NamedCompound)4 ArrayList (java.util.ArrayList)3 Collection (java.util.Collection)3 JabRefFrame (org.jabref.gui.JabRefFrame)3 IOException (java.io.IOException)2 SQLException (java.sql.SQLException)2 List (java.util.List)2 Map (java.util.Map)2 TimeUnit (java.util.concurrent.TimeUnit)2 BorderFactory (javax.swing.BorderFactory)2 JFrame (javax.swing.JFrame)2 JList (javax.swing.JList)2 JOptionPane (javax.swing.JOptionPane)2 ListSelectionModel (javax.swing.ListSelectionModel)2 ComponentFinder (org.assertj.swing.core.ComponentFinder)2 FailOnThreadViolationRepaintManager (org.assertj.swing.edt.FailOnThreadViolationRepaintManager)2 WindowFinder (org.assertj.swing.finder.WindowFinder)2