[nostalgia/core] Replace old namespace nesting with C++17 nesting

This commit is contained in:
Gary Talent 2019-03-28 06:24:20 -05:00
parent 2830eb76b6
commit 941d714630
17 changed files with 17 additions and 52 deletions

View File

@ -9,8 +9,7 @@
#include "mem.hpp"
#include "core.hpp"
namespace nostalgia {
namespace core {
namespace nostalgia::core {
ox::Error init(Context *ctx) {
ox::Error err = 0;
@ -20,4 +19,3 @@ ox::Error init(Context *ctx) {
}
}
}

View File

@ -14,10 +14,8 @@
#include "media.hpp"
#include "types.hpp"
namespace nostalgia {
namespace core {
namespace nostalgia::core {
ox::Error init(Context *ctx);
}
}

View File

@ -10,8 +10,7 @@
#include <ox/std/types.hpp>
namespace nostalgia {
namespace core {
namespace nostalgia::core {
typedef struct { uint32_t data[8]; } __attribute__((aligned(4))) Tile, Tile4;
// d-tile: double-sized tile (8bpp)
@ -33,4 +32,3 @@ struct __attribute__((packed)) GbaImageData {
};
}
}

View File

@ -17,8 +17,7 @@
#include "../gfx.hpp"
namespace nostalgia {
namespace core {
namespace nostalgia::core {
using namespace ox;
@ -249,4 +248,3 @@ void setTile(Context *ctx, int layer, int column, int row, uint8_t tile) {
}
}
}

View File

@ -12,8 +12,7 @@
#include "../media.hpp"
namespace nostalgia {
namespace core {
namespace nostalgia::core {
uint8_t *loadRom(const char*) {
// put the header in the wrong order to prevent mistaking this code for the
@ -34,4 +33,3 @@ uint8_t *loadRom(const char*) {
}
}
}

View File

@ -9,8 +9,7 @@
#include "../core.hpp"
#include "panic.hpp"
namespace nostalgia {
namespace core {
namespace nostalgia::core {
void panic(const char *msg) {
initConsole(nullptr);
@ -23,5 +22,3 @@ void panic(const char *msg) {
}
}
}

View File

@ -10,11 +10,9 @@
#include "panic.hpp"
namespace nostalgia {
namespace core {
namespace nostalgia::core {
void panic(const char *msg);
}
}

View File

@ -13,8 +13,7 @@
#include "context.hpp"
#include "types.hpp"
namespace nostalgia {
namespace core {
namespace nostalgia::core {
ox::Error initGfx(Context *ctx);
@ -27,4 +26,3 @@ void puts(Context *ctx, int loc, const char *str);
void setTile(Context *ctx, int layer, int column, int row, uint8_t tile);
}
}

View File

@ -10,10 +10,8 @@
#include <ox/std/types.hpp>
namespace nostalgia {
namespace core {
namespace nostalgia::core {
uint8_t *loadRom(const char *path = "");
}
}

View File

@ -6,10 +6,8 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
namespace nostalgia {
namespace core {
namespace nostalgia::core {
void initHeap();
}
}

View File

@ -8,8 +8,7 @@
#include "../gfx.hpp"
namespace nostalgia {
namespace core {
namespace nostalgia::core {
ox::Error initGfx(Context *ctx) {
return 1;
@ -30,4 +29,3 @@ void setTile(Context *ctx, int layer, int column, int row, uint8_t tile) {
}
}
}

View File

@ -11,8 +11,7 @@
#include "import_tilesheet_wizard.hpp"
namespace nostalgia {
namespace core {
namespace nostalgia::core {
const QString ImportTilesheetWizardPage::TileSheetDir = "/TileSheets/";
const QString ImportTilesheetWizardPage::TileSheetName = "projectName";
@ -75,4 +74,3 @@ int ImportTilesheetWizardPage::importImage(QFile &srcFile, QString tilesheetName
}
}
}

View File

@ -10,8 +10,7 @@
#include <nostalgia/studio/studio.hpp>
namespace nostalgia {
namespace core {
namespace nostalgia::core {
class ImportTilesheetWizardPage: public studio::WizardFormPage {
private:
@ -31,4 +30,3 @@ class ImportTilesheetWizardPage: public studio::WizardFormPage {
};
}
}

View File

@ -12,8 +12,7 @@
using namespace nostalgia::studio;
namespace nostalgia {
namespace core {
namespace nostalgia::core {
Plugin::Plugin() {
}
@ -32,4 +31,3 @@ QVector<studio::WizardMaker> Plugin::importWizards(const studio::Context *args)
}
}
}

View File

@ -12,8 +12,7 @@
#include <nostalgia/studio/studio.hpp>
namespace nostalgia {
namespace core {
namespace nostalgia::core {
class Plugin: public QObject, studio::Plugin {
Q_OBJECT
@ -27,4 +26,3 @@ class Plugin: public QObject, studio::Plugin {
};
}
}

View File

@ -11,12 +11,10 @@
#include "../media.hpp"
namespace nostalgia {
namespace core {
namespace nostalgia::core {
uint8_t *loadRom(const char*) {
return nullptr;
}
}
}

View File

@ -6,11 +6,9 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
namespace nostalgia {
namespace core {
namespace nostalgia::core {
void initHeap() {
}
}
}