mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 00:47:45 +00:00
file: Remove unused static description strings
This commit is contained in:
parent
d7446e05db
commit
2ddd2d0866
1 changed files with 17 additions and 22 deletions
|
@ -35,29 +35,24 @@ static Optional<String> image_details(const String& description, const String& p
|
||||||
}
|
}
|
||||||
|
|
||||||
#define ENUMERATE_DESCRIPTION_CONTENTS(V) \
|
#define ENUMERATE_DESCRIPTION_CONTENTS(V) \
|
||||||
V(pbm, "image/x-portable-bitmap", "PBM image data", image_details) \
|
V("image/x-portable-bitmap", "PBM image data", image_details) \
|
||||||
V(pgm, "image/x-portable-graymap", "PGM image data", image_details) \
|
V("image/x-portable-graymap", "PGM image data", image_details) \
|
||||||
V(png, "image/png", "PNG image data", image_details) \
|
V("image/png", "PNG image data", image_details) \
|
||||||
V(ppm, "image/x-portable-pixmap", "PPM image data", image_details) \
|
V("image/x-portable-pixmap", "PPM image data", image_details) \
|
||||||
V(gif_87, "image/gif", "GIF image data", image_details) \
|
V("image/gif", "GIF image data", image_details) \
|
||||||
V(gif_89, "image/gif", "GIF image data", image_details) \
|
V("image/gif", "GIF image data", image_details) \
|
||||||
V(bmp, "image/bmp", "BMP image data", image_details) \
|
V("image/bmp", "BMP image data", image_details) \
|
||||||
V(jpeg, "image/jpeg", "JPEG image data", image_details) \
|
V("image/jpeg", "JPEG image data", image_details) \
|
||||||
V(jpeg_jfif, "image/jpeg", "JFIF image data", image_details) \
|
V("image/jpeg", "JFIF image data", image_details) \
|
||||||
V(jpeg_huh, "image/jpeg", "JPEG image data", image_details) \
|
V("image/jpeg", "JPEG image data", image_details) \
|
||||||
V(shell, "text/x-shellscript", "POSIX shell script text executable", description_only) \
|
V("text/x-shellscript", "POSIX shell script text executable", description_only) \
|
||||||
V(json, "application/json", "JSON data", description_only) \
|
V("application/json", "JSON data", description_only) \
|
||||||
V(javascript, "application/javascript", "JavaScript source", description_only) \
|
V("application/javascript", "JavaScript source", description_only) \
|
||||||
V(markdown, "text/markdown", "Markdown document", description_only)
|
V("text/markdown", "Markdown document", description_only)
|
||||||
|
|
||||||
#define V(var_name, mime_type, description, details) \
|
|
||||||
static const String var_name = description;
|
|
||||||
ENUMERATE_DESCRIPTION_CONTENTS(V)
|
|
||||||
#undef V
|
|
||||||
|
|
||||||
static Optional<String> get_description_from_mime_type(const String& mime, const String& path)
|
static Optional<String> get_description_from_mime_type(const String& mime, const String& path)
|
||||||
{
|
{
|
||||||
#define V(var_name, mime_type, description, details) \
|
#define V(mime_type, description, details) \
|
||||||
if (String(mime_type) == mime) \
|
if (String(mime_type) == mime) \
|
||||||
return details(String(description), path);
|
return details(String(description), path);
|
||||||
ENUMERATE_DESCRIPTION_CONTENTS(V);
|
ENUMERATE_DESCRIPTION_CONTENTS(V);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue