Fix instanciate_catalog prototype

The prototype didn't match what the Locale Kit actually uses, making the
plaintext catalog (and any other add-on) unusable.
This commit is contained in:
Adrien Destugues
2015-01-17 17:02:40 +01:00
parent 412f030b0f
commit 4bb4130ff2
3 changed files with 42 additions and 12 deletions
+2 -2
View File
@@ -99,8 +99,8 @@ BCatalogData::Next()
//
// 1. the function that instantiates a catalog for this add-on-type
extern "C"
BCatalogData* instantiate_catalog(const char* signature, const char* language,
uint32 fingerprint);
BCatalogData* instantiate_catalog(const entry_ref& signature,
const char* language, uint32 fingerprint);
// 2. the function that creates an empty catalog for this add-on-type
extern "C"
+4 -4
View File
@@ -18,22 +18,22 @@ namespace BPrivate {
class PlainTextCatalog : public HashMapCatalog {
public:
PlainTextCatalog(const char *signature, const char *language,
PlainTextCatalog(const entry_ref& owner, const char *language,
uint32 fingerprint);
// constructor for normal use
PlainTextCatalog(entry_ref *appOrAddOnRef);
// constructor for embedded catalog
PlainTextCatalog(const char *path, const char *signature,
const char *language);
// constructor for editor-app
~PlainTextCatalog();
void SetSignature(const entry_ref &catalogOwner);
// implementation for editor-interface:
status_t ReadFromFile(const char *path = NULL);
status_t WriteToFile(const char *path = NULL);
static BCatalogData *Instantiate(const char *signature,
static BCatalogData *Instantiate(const entry_ref &signature,
const char *language, uint32 fingerprint);
static const char *kCatMimeType;