From f5ec938ddbbe3cffe1667c203da0ce3f8b07adae Mon Sep 17 00:00:00 2001 From: dreamsourcelabTAI Date: Mon, 27 Jun 2022 16:03:19 +0800 Subject: [PATCH] update: rename namespace --- DSView/pv/utility/encoding.cpp | 6 ++++-- DSView/pv/utility/encoding.h | 6 ++++-- DSView/pv/utility/path.cpp | 6 ++++-- DSView/pv/utility/path.h | 5 +++-- 4 files changed, 15 insertions(+), 8 deletions(-) diff --git a/DSView/pv/utility/encoding.cpp b/DSView/pv/utility/encoding.cpp index 12cccf1c..41bf23c6 100644 --- a/DSView/pv/utility/encoding.cpp +++ b/DSView/pv/utility/encoding.cpp @@ -28,8 +28,9 @@ #include #endif -namespace pv::encoding -{ +namespace pv{ +namespace encoding{ + void set_utf8(QTextStream &stream) { #if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) @@ -39,4 +40,5 @@ namespace pv::encoding stream.setCodec(code); #endif } +} } \ No newline at end of file diff --git a/DSView/pv/utility/encoding.h b/DSView/pv/utility/encoding.h index f1584f46..b4e8858b 100644 --- a/DSView/pv/utility/encoding.h +++ b/DSView/pv/utility/encoding.h @@ -24,9 +24,11 @@ class QTextStream; -namespace pv::encoding -{ +namespace pv{ +namespace encoding{ + void set_utf8(QTextStream &stream); } +} #endif \ No newline at end of file diff --git a/DSView/pv/utility/path.cpp b/DSView/pv/utility/path.cpp index 692f3166..602563d1 100644 --- a/DSView/pv/utility/path.cpp +++ b/DSView/pv/utility/path.cpp @@ -21,8 +21,9 @@ #include "path.h" -namespace pv::path -{ +namespace pv{ +namespace path{ + std::string ConvertPath(QString fileName) { return fileName.toUtf8().toStdString(); @@ -37,4 +38,5 @@ namespace pv::path } return path; } +} } \ No newline at end of file diff --git a/DSView/pv/utility/path.h b/DSView/pv/utility/path.h index 4d42a6d9..7d6e40a7 100644 --- a/DSView/pv/utility/path.h +++ b/DSView/pv/utility/path.h @@ -25,11 +25,12 @@ #include #include -namespace pv::path -{ +namespace pv{ +namespace path{ std::string ConvertPath(QString fileName); QString GetDirectoryName(QString path); } +} #endif \ No newline at end of file