equal
deleted
inserted
replaced
14 * |
14 * |
15 * Description: |
15 * Description: |
16 * |
16 * |
17 */ |
17 */ |
18 |
18 |
19 // when enabled this macro copies the database to c:\data on launch for debug purposes |
|
20 //#define COPY_DB |
|
21 |
|
22 #include <commdb.h> |
19 #include <commdb.h> |
23 #include "PodcastModel.h" |
20 #include "PodcastModel.h" |
24 #include "FeedEngine.h" |
21 #include "FeedEngine.h" |
25 #include "SettingsEngine.h" |
22 #include "SettingsEngine.h" |
26 #include "ShowEngine.h" |
23 #include "ShowEngine.h" |
316 // copy template to new DB |
313 // copy template to new DB |
317 TFileName dbTemplate; |
314 TFileName dbTemplate; |
318 dbTemplate.Copy(iSettingsEngine->PrivatePath()); |
315 dbTemplate.Copy(iSettingsEngine->PrivatePath()); |
319 dbTemplate.Append(KDBTemplateFileName); |
316 dbTemplate.Append(KDBTemplateFileName); |
320 |
317 |
|
318 DP1("Copy template DB from: %S", &dbTemplate); |
|
319 DP1("Copy template DB to: %S", &dbFileName); |
|
320 |
321 BaflUtils::CopyFile(iFsSession, dbTemplate,dbFileName); |
321 BaflUtils::CopyFile(iFsSession, dbTemplate,dbFileName); |
|
322 |
|
323 // important to set this file to not be read only if copying from Z: |
|
324 iFsSession.SetAtt(dbFileName, 0, KEntryAttReadOnly); |
|
325 |
322 iIsFirstStartup = ETrue; |
326 iIsFirstStartup = ETrue; |
323 DP("CPodcastModel::ResetDB END"); |
327 DP("CPodcastModel::ResetDB END"); |
324 } |
328 } |
325 |
329 |
326 |
330 |