ZRCola.zrcdb installation added
This commit is contained in:
parent
54802ec29a
commit
e5711cc6b5
@ -56,6 +56,8 @@ Component Component
|
|||||||
compwxstd.mo.sl_SI {A5FEEA94-08CA-4E12-993F-A115601EF258} ZRCOLALOCSLSIDIR $(MSIBUILD_COMPONENT_ATTRIB_FILE) filewxstd.mo.sl_SI
|
compwxstd.mo.sl_SI {A5FEEA94-08CA-4E12-993F-A115601EF258} ZRCOLALOCSLSIDIR $(MSIBUILD_COMPONENT_ATTRIB_FILE) filewxstd.mo.sl_SI
|
||||||
compLocalizationRepositoryPath {0E96110A-C38D-4600-9AE2-B8B59AF53A00} ZRCOLALOCDIR $(MSIBUILD_COMPONENT_ATTRIB_REGISTRY) regLocalizationRepositoryPath
|
compLocalizationRepositoryPath {0E96110A-C38D-4600-9AE2-B8B59AF53A00} ZRCOLALOCDIR $(MSIBUILD_COMPONENT_ATTRIB_REGISTRY) regLocalizationRepositoryPath
|
||||||
compLanguage {B78359AC-9484-402C-8384-3A4595B39389} ZRCOLALOCDIR $(MSIBUILD_COMPONENT_ATTRIB_REGISTRY) regLanguage
|
compLanguage {B78359AC-9484-402C-8384-3A4595B39389} ZRCOLALOCDIR $(MSIBUILD_COMPONENT_ATTRIB_REGISTRY) regLanguage
|
||||||
|
compDatabasePath {DF3C720D-50BB-4377-9EE0-9AC21C02B9DD} ZRCOLADATADIR $(MSIBUILD_COMPONENT_ATTRIB_REGISTRY) regDatabasePath
|
||||||
|
compZRCola.zrcdb {0585A51F-1411-43A3-AC50-F04A253FDED4} ZRCOLADATADIR $(MSIBUILD_COMPONENT_ATTRIB_FILE) fileZRCola.zrcdb
|
||||||
comp00_ZRCola_Re.ttf {B6CE8B39-11DC-4B59-B10C-3F0FFE8F81AF} FontsFolder 0 file00_ZRCola_Re.ttf
|
comp00_ZRCola_Re.ttf {B6CE8B39-11DC-4B59-B10C-3F0FFE8F81AF} FontsFolder 0 file00_ZRCola_Re.ttf
|
||||||
comp00_ZRCola_It.ttf {10613965-2874-470D-9D5A-B7D535AA3317} FontsFolder 0 file00_ZRCola_It.ttf
|
comp00_ZRCola_It.ttf {10613965-2874-470D-9D5A-B7D535AA3317} FontsFolder 0 file00_ZRCola_It.ttf
|
||||||
comp00_ZRCola_Bd.ttf {C036BE8D-6D2F-4DBF-99D6-F53702EAEBB6} FontsFolder 0 file00_ZRCola_Bd.ttf
|
comp00_ZRCola_Bd.ttf {C036BE8D-6D2F-4DBF-99D6-F53702EAEBB6} FontsFolder 0 file00_ZRCola_Bd.ttf
|
||||||
@ -142,6 +144,7 @@ ZRCOLABINDIR ZRCOLADIR .:X64~1.REL|x64.Release
|
|||||||
!ENDIF
|
!ENDIF
|
||||||
ZRCOLALOCDIR ZRCOLADIR locale
|
ZRCOLALOCDIR ZRCOLADIR locale
|
||||||
ZRCOLALOCSLSIDIR ZRCOLALOCDIR sl_SI
|
ZRCOLALOCSLSIDIR ZRCOLALOCDIR sl_SI
|
||||||
|
ZRCOLADATADIR ZRCOLADIR data
|
||||||
<<NOKEEP
|
<<NOKEEP
|
||||||
|
|
||||||
"En.$(PLAT).$(CFG).Directory-2.idtx" : "Makefile" "..\..\include\MSIBuildCfg.mak"
|
"En.$(PLAT).$(CFG).Directory-2.idtx" : "Makefile" "..\..\include\MSIBuildCfg.mak"
|
||||||
@ -224,6 +227,7 @@ File Component_ FileName FileSize Version Language Attributes Sequence
|
|||||||
s$(MSIBUILD_LENGTH_ID) s$(MSIBUILD_LENGTH_ID) l255 i4 S$(MSIBUILD_LENGTH_ID) S20 I2 i2
|
s$(MSIBUILD_LENGTH_ID) s$(MSIBUILD_LENGTH_ID) l255 i4 S$(MSIBUILD_LENGTH_ID) S20 I2 i2
|
||||||
File File
|
File File
|
||||||
filewxstd.mo.sl_SI compwxstd.mo.sl_SI wxstd.mo 0 1060 0 1
|
filewxstd.mo.sl_SI compwxstd.mo.sl_SI wxstd.mo 0 1060 0 1
|
||||||
|
fileZRCola.zrcdb compZRCola.zrcdb ZRCOLA~1.ZRC|ZRCola.zrcdb 0 0 1
|
||||||
file00_ZRCola_Re.ttf comp00_ZRCola_Re.ttf 00_ZRC~1.TTF|00_ZRCola_Re.ttf 0 0 1
|
file00_ZRCola_Re.ttf comp00_ZRCola_Re.ttf 00_ZRC~1.TTF|00_ZRCola_Re.ttf 0 0 1
|
||||||
file00_ZRCola_It.ttf comp00_ZRCola_It.ttf 00_ZRC~2.TTF|00_ZRCola_It.ttf 0 0 1
|
file00_ZRCola_It.ttf comp00_ZRCola_It.ttf 00_ZRC~2.TTF|00_ZRCola_It.ttf 0 0 1
|
||||||
file00_ZRCola_Bd.ttf comp00_ZRCola_Bd.ttf 00_ZRC~3.TTF|00_ZRCola_Bd.ttf 0 0 1
|
file00_ZRCola_Bd.ttf comp00_ZRCola_Bd.ttf 00_ZRC~3.TTF|00_ZRCola_Bd.ttf 0 0 1
|
||||||
@ -329,6 +333,7 @@ Registry Root Key Name Value Component_
|
|||||||
s$(MSIBUILD_LENGTH_ID) i2 l255 L255 L0 s$(MSIBUILD_LENGTH_ID)
|
s$(MSIBUILD_LENGTH_ID) i2 l255 L255 L0 s$(MSIBUILD_LENGTH_ID)
|
||||||
Registry Registry
|
Registry Registry
|
||||||
regLocalizationRepositoryPath 2 SOFTWARE\Amebis\ZRCola LocalizationRepositoryPath [ZRCOLALOCDIR] compLocalizationRepositoryPath
|
regLocalizationRepositoryPath 2 SOFTWARE\Amebis\ZRCola LocalizationRepositoryPath [ZRCOLALOCDIR] compLocalizationRepositoryPath
|
||||||
|
regDatabasePath 2 SOFTWARE\Amebis\ZRCola DatabasePath [ZRCOLADATADIR] compDatabasePath
|
||||||
<<NOKEEP
|
<<NOKEEP
|
||||||
|
|
||||||
"En.$(PLAT).$(CFG).Registry-2.idtx" : "Makefile" "..\..\include\MSIBuildCfg.mak"
|
"En.$(PLAT).$(CFG).Registry-2.idtx" : "Makefile" "..\..\include\MSIBuildCfg.mak"
|
||||||
|
4
Makefile
4
Makefile
@ -128,14 +128,18 @@ Unregister :: \
|
|||||||
|
|
||||||
RegisterSettings ::
|
RegisterSettings ::
|
||||||
reg.exe add "HKLM\Software\Amebis\ZRCola" /v "LocalizationRepositoryPath" /t REG_SZ /d "$(MAKEDIR)\$(OUTPUT_DIR)\locale" $(REG_FLAGS) > NUL
|
reg.exe add "HKLM\Software\Amebis\ZRCola" /v "LocalizationRepositoryPath" /t REG_SZ /d "$(MAKEDIR)\$(OUTPUT_DIR)\locale" $(REG_FLAGS) > NUL
|
||||||
|
reg.exe add "HKLM\Software\Amebis\ZRCola" /v "DatabasePath" /t REG_SZ /d "$(MAKEDIR)\$(OUTPUT_DIR)\data" $(REG_FLAGS) > NUL
|
||||||
!IF "$(PROCESSOR_ARCHITECTURE)" == "AMD64"
|
!IF "$(PROCESSOR_ARCHITECTURE)" == "AMD64"
|
||||||
reg.exe add "HKLM\Software\Amebis\ZRCola" /v "LocalizationRepositoryPath" /t REG_SZ /d "$(MAKEDIR)\$(OUTPUT_DIR)\locale" $(REG_FLAGS32) > NUL
|
reg.exe add "HKLM\Software\Amebis\ZRCola" /v "LocalizationRepositoryPath" /t REG_SZ /d "$(MAKEDIR)\$(OUTPUT_DIR)\locale" $(REG_FLAGS32) > NUL
|
||||||
|
reg.exe add "HKLM\Software\Amebis\ZRCola" /v "DatabasePath" /t REG_SZ /d "$(MAKEDIR)\$(OUTPUT_DIR)\data" $(REG_FLAGS32) > NUL
|
||||||
!ENDIF
|
!ENDIF
|
||||||
|
|
||||||
UnregisterSettings ::
|
UnregisterSettings ::
|
||||||
-reg.exe delete "HKLM\Software\Amebis\ZRCola" /v "LocalizationRepositoryPath" $(REG_FLAGS) > NUL
|
-reg.exe delete "HKLM\Software\Amebis\ZRCola" /v "LocalizationRepositoryPath" $(REG_FLAGS) > NUL
|
||||||
|
-reg.exe delete "HKLM\Software\Amebis\ZRCola" /v "DatabasePath" $(REG_FLAGS) > NUL
|
||||||
!IF "$(PROCESSOR_ARCHITECTURE)" == "AMD64"
|
!IF "$(PROCESSOR_ARCHITECTURE)" == "AMD64"
|
||||||
-reg.exe delete "HKLM\Software\Amebis\ZRCola" /v "LocalizationRepositoryPath" $(REG_FLAGS32) > NUL
|
-reg.exe delete "HKLM\Software\Amebis\ZRCola" /v "LocalizationRepositoryPath" $(REG_FLAGS32) > NUL
|
||||||
|
-reg.exe delete "HKLM\Software\Amebis\ZRCola" /v "DatabasePath" $(REG_FLAGS32) > NUL
|
||||||
!ENDIF
|
!ENDIF
|
||||||
|
|
||||||
InstallFonts :: \
|
InstallFonts :: \
|
||||||
|
@ -125,6 +125,8 @@ featZRCola compwxExtend.mo.sl_SI
|
|||||||
featZRCola compwxstd.mo.sl_SI
|
featZRCola compwxstd.mo.sl_SI
|
||||||
featZRCola compLocalizationRepositoryPath
|
featZRCola compLocalizationRepositoryPath
|
||||||
featZRCola compLanguage
|
featZRCola compLanguage
|
||||||
|
featZRCola compDatabasePath
|
||||||
|
featZRCola compZRCola.zrcdb
|
||||||
featZRCola comp00_ZRCola_Re.ttf
|
featZRCola comp00_ZRCola_Re.ttf
|
||||||
<<NOKEEP
|
<<NOKEEP
|
||||||
|
|
||||||
|
@ -46,6 +46,13 @@ public:
|
|||||||
/// - false otherwise
|
/// - false otherwise
|
||||||
virtual bool OnInit();
|
virtual bool OnInit();
|
||||||
|
|
||||||
|
|
||||||
|
///
|
||||||
|
/// \returns Path to ZRCola.zrcdb file
|
||||||
|
///
|
||||||
|
inline wxString GetDatabasePath() const;
|
||||||
|
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
wxConfig m_config; ///< Application configuration
|
wxConfig m_config; ///< Application configuration
|
||||||
wxLocale m_locale; ///< Current locale
|
wxLocale m_locale; ///< Current locale
|
||||||
@ -53,3 +60,19 @@ protected:
|
|||||||
|
|
||||||
|
|
||||||
wxDECLARE_APP(ZRColaApp);
|
wxDECLARE_APP(ZRColaApp);
|
||||||
|
|
||||||
|
|
||||||
|
inline wxString ZRColaApp::GetDatabasePath() const
|
||||||
|
{
|
||||||
|
wxString sPath;
|
||||||
|
if (m_config.Read(wxT("DatabasePath"), &sPath)) {
|
||||||
|
if (!wxEndsWithPathSeparator(sPath))
|
||||||
|
sPath << wxFILE_SEP_PATH;
|
||||||
|
} else {
|
||||||
|
sPath = wxPathOnly(argv[0]);
|
||||||
|
sPath << wxT("\\..\\data\\");
|
||||||
|
}
|
||||||
|
sPath << wxT("ZRCola.zrcdb");
|
||||||
|
|
||||||
|
return sPath;
|
||||||
|
}
|
||||||
|
@ -30,10 +30,7 @@ wxZRColaComposerPanel::wxZRColaComposerPanel(wxWindow* parent) :
|
|||||||
m_selComposed(0, 0),
|
m_selComposed(0, 0),
|
||||||
wxZRColaComposerPanelBase(parent)
|
wxZRColaComposerPanelBase(parent)
|
||||||
{
|
{
|
||||||
wxString sPath(wxPathOnly(wxTheApp->argv[0]));
|
std::fstream dat((LPCTSTR)((ZRColaApp*)wxTheApp)->GetDatabasePath(), std::ios_base::in | std::ios_base::binary);
|
||||||
sPath << wxT("\\..\\data\\ZRCola.zrcdb"); // TODO: Make database file configurable
|
|
||||||
|
|
||||||
std::fstream dat((LPCTSTR)sPath, std::ios_base::in | std::ios_base::binary);
|
|
||||||
if (dat.good()) {
|
if (dat.good()) {
|
||||||
if (stdex::idrec::find<ZRCola::recordid_t, ZRCola::recordsize_t, ZRCOLA_RECORD_ALIGN>(dat, ZRCOLA_DB_ID, sizeof(ZRCola::recordid_t))) {
|
if (stdex::idrec::find<ZRCola::recordid_t, ZRCola::recordsize_t, ZRCOLA_RECORD_ALIGN>(dat, ZRCOLA_DB_ID, sizeof(ZRCola::recordid_t))) {
|
||||||
ZRCola::recordsize_t size;
|
ZRCola::recordsize_t size;
|
||||||
|
@ -26,10 +26,7 @@
|
|||||||
|
|
||||||
wxZRColaKeyHandler::wxZRColaKeyHandler() : wxEvtHandler()
|
wxZRColaKeyHandler::wxZRColaKeyHandler() : wxEvtHandler()
|
||||||
{
|
{
|
||||||
wxString sPath(wxPathOnly(wxTheApp->argv[0]));
|
std::fstream dat((LPCTSTR)((ZRColaApp*)wxTheApp)->GetDatabasePath(), std::ios_base::in | std::ios_base::binary);
|
||||||
sPath << wxT("\\..\\data\\ZRCola.zrcdb"); // TODO: Make database file configurable
|
|
||||||
|
|
||||||
std::fstream dat((LPCTSTR)sPath, std::ios_base::in | std::ios_base::binary);
|
|
||||||
if (dat.good()) {
|
if (dat.good()) {
|
||||||
if (stdex::idrec::find<ZRCola::recordid_t, ZRCola::recordsize_t, ZRCOLA_RECORD_ALIGN>(dat, ZRCOLA_DB_ID, sizeof(ZRCola::recordid_t))) {
|
if (stdex::idrec::find<ZRCola::recordid_t, ZRCola::recordsize_t, ZRCOLA_RECORD_ALIGN>(dat, ZRCOLA_DB_ID, sizeof(ZRCola::recordid_t))) {
|
||||||
ZRCola::recordsize_t size;
|
ZRCola::recordsize_t size;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user