Icon-O-Matic: Move some functions to header files

Change-Id: I3b12e88e133cfe8e9b0f5830f69d582bbaaa93c2
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6466
Tested-by: Commit checker robot <[email protected]>
Reviewed-by: Adrien Destugues <[email protected]>
This commit is contained in:
Zardshard
2023-05-24 10:58:19 +00:00
committed by Adrien Destugues
parent 41bd89a9fa
commit 13f2f8de06
8 changed files with 5 additions and 40 deletions
@@ -89,13 +89,6 @@ FlatIconExporter::Export(const Icon* icon, BPositionIO* stream)
return B_OK;
}
// MIMEType
const char*
FlatIconExporter::MIMEType()
{
return NULL;
}
// Export
status_t
FlatIconExporter::Export(const Icon* icon, BNode* node,
@@ -57,7 +57,7 @@ class FlatIconExporter : public Exporter {
virtual status_t Export(const Icon* icon,
BPositionIO* stream);
virtual const char* MIMEType();
virtual const char* MIMEType() { return NULL; }
/*! Export to file attribute */
status_t Export(const Icon* icon, BNode* node,
@@ -36,13 +36,6 @@ RDefExporter::Export(const Icon* icon, BPositionIO* stream)
return _Export((const uint8*)buffer.Buffer(), buffer.BufferLength(), stream);
}
// MIMEType
const char*
RDefExporter::MIMEType()
{
return "text/x-vnd.Be.ResourceDef";
}
// #pragma mark -
// _Export
@@ -21,7 +21,7 @@ class RDefExporter : public FlatIconExporter {
virtual status_t Export(const Icon* icon,
BPositionIO* stream);
virtual const char* MIMEType();
virtual const char* MIMEType() { return "text/x-vnd.Be.ResourceDef"; }
private:
status_t _Export(const uint8* source,
@@ -37,13 +37,6 @@ SourceExporter::Export(const Icon* icon, BPositionIO* stream)
stream);
}
// MIMEType
const char*
SourceExporter::MIMEType()
{
return "text/x-source-code";
}
// #pragma mark -
// _Export
@@ -21,7 +21,7 @@ class SourceExporter : public FlatIconExporter {
virtual status_t Export(const Icon* icon,
BPositionIO* stream);
virtual const char* MIMEType();
virtual const char* MIMEType() { return "text/x-source-code"; }
private:
status_t _Export(const uint8* source,
@@ -125,20 +125,6 @@ SVGExporter::Export(const Icon* icon, BPositionIO* stream)
return ret;
}
// MIMEType
const char*
SVGExporter::MIMEType()
{
return "image/svg+xml";
}
// Extension
const char*
SVGExporter::Extension()
{
return "svg";
}
// #pragma mark -
// SetOriginalEntry
@@ -32,8 +32,8 @@ class SVGExporter : public Exporter {
// Exporter
virtual status_t Export(const Icon* icon, BPositionIO* stream);
virtual const char* MIMEType();
virtual const char* Extension();
virtual const char* MIMEType() { return "image/svg+xml"; }
virtual const char* Extension() { return "svg"; }
// SVGExporter
void SetOriginalEntry(const entry_ref* ref);