Ignore:
Timestamp:
Sep 20, 2021, 11:36:06 AM (3 years ago)
Author:
chronos
Message:
  • Modified: Show items without active filter text active by default to show supported acronyms immediatelly after application start.
  • Added: Snap package definition file.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Forms/UFormMain.pas

    r207 r208  
    1717  TFormMain = class(TForm)
    1818    AboutDialog1: TAboutDialog;
     19    AFilterShowItemsWithoutFilter: TAction;
    1920    ADocumentCheck: TAction;
    2021    AFilterEnabledCategories: TAction;
     
    4142    ActionList1: TActionList;
    4243    CheckBoxEnabledCategories: TCheckBox;
     44    CheckBoxShowItemsWithoutFilter: TCheckBox;
    4345    CheckBoxExactLength: TCheckBox;
    4446    CheckBoxCaseSensitive: TCheckBox;
     
    5052    MainMenu1: TMainMenu;
    5153    MenuItem1: TMenuItem;
     54    MenuItem19: TMenuItem;
    5255    MenuItem2: TMenuItem;
     56    MenuItem26: TMenuItem;
     57    MenuItem27: TMenuItem;
     58    N1: TMenuItem;
    5359    MenuItem3: TMenuItem;
    5460    MenuItemShowItemsWithoutFilter: TMenuItem;
     
    113119    procedure AFilterSameLetterCaseExecute(Sender: TObject);
    114120    procedure AFilterSameLengthExecute(Sender: TObject);
     121    procedure AFilterShowItemsWithoutFilterExecute(Sender: TObject);
    115122    procedure AHideExecute(Sender: TObject);
    116123    procedure AImportExecute(Sender: TObject);
     
    142149    procedure ListViewSort1Filter(ListViewSort: TListViewSort);
    143150    procedure MenuItemParamClick(Sender: TObject);
    144     procedure MenuItemShowItemsWithoutFilterClick(Sender: TObject);
    145151    procedure MenuItemStatusBarClick(Sender: TObject);
    146152    procedure MenuItemToolbarClick(Sender: TObject);
     
    181187uses
    182188  UFormImport, UFormSettings, UFormCategories, UFormAcronyms, UFormExport,
    183   UFormImportSources, UFormAbout, UFormImportFormats, UCore, UFormCheck;
     189  UFormImportSources, UFormImportFormats, UCore, UFormCheck;
    184190
    185191resourcestring
     
    365371end;
    366372
     373procedure TFormMain.AFilterShowItemsWithoutFilterExecute(Sender: TObject);
     374begin
     375  UpdateAcronymsList;
     376end;
     377
    367378procedure TFormMain.AHideExecute(Sender: TObject);
    368379begin
     
    586597end;
    587598
    588 procedure TFormMain.MenuItemShowItemsWithoutFilterClick(Sender: TObject);
    589 begin
    590   MenuItemShowItemsWithoutFilter.Checked :=
    591     not MenuItemShowItemsWithoutFilter.Checked;
    592   UpdateAcronymsList;
    593   UpdateInterface;
    594 end;
    595 
    596599procedure TFormMain.MenuItemStatusBarClick(Sender: TObject);
    597600begin
     
    662665         with ListViewFilter1 do
    663666         if Visible and ((EnteredCount > 0) or ((EnteredCount = 0) and
    664          (MenuItemShowItemsWithoutFilter.Checked))) then begin
     667         (AFilterShowItemsWithoutFilter.Checked))) then begin
    665668           FoundCount := 0;
    666669           if TextEnteredColumn(0) and (FilterCell(StringGrid.Cells[0, 0],
     
    768771    MenuItemStatusBar.Checked := ReadBoolWithDefault('StatusBarVisible', True);
    769772    MenuItemParam.Checked := ReadBoolWithDefault('FilterParamVisible', True);
    770     MenuItemShowItemsWithoutFilter.Checked :=
    771       ReadBoolWithDefault('ShowItemsWithoutFilter', False);
     773    AFilterShowItemsWithoutFilter.Checked :=
     774      ReadBoolWithDefault('ShowItemsWithoutFilter', True);
    772775  finally
    773776    Free;
     
    799802    WriteBool('StatusBarVisible', MenuItemStatusBar.Checked);
    800803    WriteBool('FilterParamVisible', MenuItemParam.Checked);
    801     WriteBool('ShowItemsWithoutFilter', MenuItemShowItemsWithoutFilter.Checked);
     804    WriteBool('ShowItemsWithoutFilter', AFilterShowItemsWithoutFilter.Checked);
    802805  finally
    803806    Free;
Note: See TracChangeset for help on using the changeset viewer.