File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change 33 * v. 2.0. If a copy of the MPL was not distributed with this file, You can
44 * obtain one at http://mozilla.org/MPL/2.0/
55 *
6- * Copyright (C) 2005-2020 , Peter Johnson (gravatar.com/delphidabbler).
6+ * Copyright (C) 2005-2021 , Peter Johnson (gravatar.com/delphidabbler).
77 *
88 * Defines a class that manages generation, previewing and saving of a code
99 * snippet.
@@ -92,7 +92,8 @@ implementation
9292
9393resourcestring
9494 // Dialog box title
95- sSaveDlgTitle = ' Save %0:s Snippet' ;
95+ sSaveSnippetDlgTitle = ' Save %0:s Snippet' ;
96+ sSaveCategoryDlgTitle = ' Save %0:s Category' ;
9697 // Output document title for snippets and categories
9798 sDocTitle = ' "%0:s" %1:s' ;
9899 sCategory = ' category' ;
@@ -145,7 +146,12 @@ function TSaveSnippetMgr.GetDlgHelpKeyword: string;
145146
146147function TSaveSnippetMgr.GetDlgTitle : string;
147148begin
148- Result := Format(sSaveDlgTitle, [fView.Description]);
149+ if Supports(fView, ICategoryView) then
150+ Result := Format(sSaveCategoryDlgTitle, [fView.Description])
151+ else if Supports(fView, ISnippetView) then
152+ Result := Format(sSaveSnippetDlgTitle, [fView.Description])
153+ else
154+ Result := ' ' ;
149155end ;
150156
151157function TSaveSnippetMgr.GetDocTitle : string;
You can’t perform that action at this time.
0 commit comments