diff --git a/.gitattributes b/.gitattributes index d9f7e7df44..95eb878aed 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1294,6 +1294,9 @@ components/favorites/README.txt svneol=native#text/plain components/favorites/favorites.lpk svneol=native#text/plain components/favorites/favorites.pas svneol=native#text/pascal components/favorites/favorites_impl.pas svneol=native#text/pascal +components/favorites/favoritesstr.pas svneol=native#text/pascal +components/favorites/languages/favoritesstr.hu.po svneol=native#text/plain +components/favorites/languages/favoritesstr.po svneol=native#text/plain components/filebrowser/frmconfigfilebrowser.lfm svneol=native#text/plain components/filebrowser/frmconfigfilebrowser.pp svneol=native#text/plain components/filebrowser/frmfilebrowser.lfm svneol=native#text/plain diff --git a/components/favorites/favorites.lpk b/components/favorites/favorites.lpk index a79de400ac..fb55c62a10 100644 --- a/components/favorites/favorites.lpk +++ b/components/favorites/favorites.lpk @@ -9,6 +9,7 @@ + @@ -30,13 +31,22 @@ - + + + + + + + + + + diff --git a/components/favorites/favorites.pas b/components/favorites/favorites.pas index aaf815b70b..f7a20a077a 100644 --- a/components/favorites/favorites.pas +++ b/components/favorites/favorites.pas @@ -7,7 +7,7 @@ unit favorites; interface uses - favorites_impl, LazarusPackageIntf; + favorites_impl, favoritesstr, LazarusPackageIntf; implementation diff --git a/components/favorites/favorites_impl.pas b/components/favorites/favorites_impl.pas index 2aa47fe97c..ce40139fde 100644 --- a/components/favorites/favorites_impl.pas +++ b/components/favorites/favorites_impl.pas @@ -32,7 +32,7 @@ interface uses Classes, SysUtils, ToolBarIntf, IDEImagesIntf, Graphics, PackageIntf, Menus, LazIDEIntf, ProjectIntf, Laz2_XMLCfg, IDEOptionsIntf, - IDECommands, ComCtrls; + IDECommands, ComCtrls, IDEMsgIntf, favoritesstr; type TFavoritesHandler = class @@ -164,9 +164,9 @@ begin xAddToFav := TFileNameMenuItem.Create(Self); xAddToFav.FileName := xProj.ProjectInfoFile; if not FavHandler.IsInFavoriteProjects(xProj.ProjectInfoFile) then - xAddToFav.Caption := Format('Add to favorites: %s', [xProj.ProjectInfoFile]) // To-Do: localize + xAddToFav.Caption := Format(sAddToFavoritesS, [xProj.ProjectInfoFile]) else - xAddToFav.Caption := Format('Remove from favorites: %s', [xProj.ProjectInfoFile]); // To-Do: localize + xAddToFav.Caption := Format(sRemoveFromFavoritesS, [xProj.ProjectInfoFile]); xAddToFav.OnClick := @mnuAddRemoveActiveProject; xM.Insert(xMIndex, xAddToFav); Inc(xMIndex); diff --git a/components/favorites/favoritesstr.pas b/components/favorites/favoritesstr.pas new file mode 100644 index 0000000000..84ea0b3475 --- /dev/null +++ b/components/favorites/favoritesstr.pas @@ -0,0 +1,13 @@ +unit favoritesstr; + +{$mode objfpc}{$H+} + +interface + +resourcestring + sAddToFavoritesS = 'Add to favorites: %s'; + sRemoveFromFavoritesS = 'Remove from favorites: %s'; + +implementation + +end. diff --git a/components/favorites/languages/favoritesstr.hu.po b/components/favorites/languages/favoritesstr.hu.po new file mode 100644 index 0000000000..a7ba1f5cf3 --- /dev/null +++ b/components/favorites/languages/favoritesstr.hu.po @@ -0,0 +1,21 @@ +msgid "" +msgstr "" +"Project-Id-Version: \n" +"POT-Creation-Date: \n" +"PO-Revision-Date: \n" +"Last-Translator: Péter Gábor \n" +"Language-Team: Magyar (Hungarian)\n" +"Language: hu\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: Poedit 1.5.4\n" + +#: favoritesstr.saddtofavoritess +msgid "Add to favorites: %s" +msgstr "Hozzáadás a kedvencekhez: %s" + +#: favoritesstr.sremovefromfavoritess +msgid "Remove from favorites: %s" +msgstr "Eltávolítás a kedvencek közül: %s" + diff --git a/components/favorites/languages/favoritesstr.po b/components/favorites/languages/favoritesstr.po new file mode 100644 index 0000000000..cca319f307 --- /dev/null +++ b/components/favorites/languages/favoritesstr.po @@ -0,0 +1,11 @@ +msgid "" +msgstr "Content-Type: text/plain; charset=UTF-8" + +#: favoritesstr.saddtofavoritess +msgid "Add to favorites: %s" +msgstr "" + +#: favoritesstr.sremovefromfavoritess +msgid "Remove from favorites: %s" +msgstr "" +