Skip to content

Commit

Permalink
split ff7tkQtWidgets from ff7tkWidget
Browse files Browse the repository at this point in the history
  • Loading branch information
sithlord48 committed Jul 26, 2022
1 parent 20ea21c commit 91d9337
Show file tree
Hide file tree
Showing 46 changed files with 101 additions and 68 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 3.21)
cmake_policy(SET CMP0074 NEW)

#Version will be written by tag v1.2.2-4
project(ff7tk VERSION 0.83.0.0 DESCRIPTION "Work with Final Fantasy 7 game data")
project(ff7tk VERSION 0.82.0.0 DESCRIPTION "Work with Final Fantasy 7 game data")

#Prevent In-sourcebuild
if(CMAKE_BINARY_DIR STREQUAL CMAKE_SOURCE_DIR)
Expand Down
65 changes: 2 additions & 63 deletions src/widgets/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,63 +1,2 @@
find_package(Qt6 REQUIRED NO_MODULE COMPONENTS
Core
Widgets
Gui
)

find_library(ff7tk ${CMAKE_CURRENT_BINARY_DIR}/src/data)

set ( ff7tkWidgets_SRC
AchievementEditor.cpp
CharEditor.cpp
ChocoboEditor.cpp
ChocoboLabel.cpp
ChocoboManager.cpp
DialogPreview.cpp
DoubleCheckBox.cpp
ItemList.cpp
ItemListView.cpp
ItemPreview.cpp
ItemSelector.cpp
ItemSelectionDelegate.cpp
LocationViewer.cpp
MateriaEditor.cpp
MenuListWidget.cpp
MetadataCreator.cpp
OptionsWidget.cpp
PhsListWidget.cpp
SlotPreview.cpp
SlotSelect.cpp
)

set (ff7tkWidgets_HEADERS
AchievementEditor.h
ChocoboLabel.h
DoubleCheckBox.h
ItemSelector.h
ItemSelectionDelegate.h
MenuListWidget.h
PhsListWidget.h
CharEditor.h
ChocoboManager.h
ItemList.h
ItemListView.h
LocationViewer.h
MetadataCreator.h
SlotPreview.h
ChocoboEditor.h
DialogPreview.h
ItemPreview.h
MateriaEditor.h
OptionsWidget.h
SlotSelect.h
${CMAKE_CURRENT_BINARY_DIR}/ff7tkwidgets_export.h
)

set( ff7tkWidgets_PublicLIBLINKS
Qt::Core
Qt::Widgets
Qt::Gui
ff7tk::ff7tk
)

MAKE_LIBRARY(ff7tkWidgets ff7tk/widgets)
add_subdirectory(common)
add_subdirectory(data)
24 changes: 24 additions & 0 deletions src/widgets/common/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
find_package(Qt6 REQUIRED NO_MODULE COMPONENTS
Core
Widgets
Gui
)

set ( ff7tkQtWidgets_SRC
DialogPreview.cpp
DoubleCheckBox.cpp
)

set (ff7tkQtWidgets_HEADERS
DialogPreview.h
DoubleCheckBox.h
${CMAKE_CURRENT_BINARY_DIR}/ff7tkqtwidgets_export.h
)

set( ff7tkQtWidgets_PublicLIBLINKS
Qt::Core
Qt::Widgets
Qt::Gui
)

MAKE_LIBRARY(ff7tkQtWidgets ff7tk/widgets/common)
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
#pragma once

#include <QLabel>
#include <ff7tkwidgets_export.h>
#include <ff7tkqtwidgets_export.h>

class FF7TKWIDGETS_EXPORT DialogPreview : public QLabel
class FF7TKQTWIDGETS_EXPORT DialogPreview : public QLabel
{
Q_OBJECT

Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@
#pragma once

#include <QWidget>
#include <ff7tkwidgets_export.h>
#include <ff7tkqtwidgets_export.h>

class QCheckBox;
class QLabel;

/** \class DoubleCheckBox
* \brief one text two checkable boxes
*/
class FF7TKWIDGETS_EXPORT DoubleCheckBox : public QWidget
class FF7TKQTWIDGETS_EXPORT DoubleCheckBox : public QWidget
{
Q_OBJECT
public:
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
61 changes: 61 additions & 0 deletions src/widgets/data/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
find_package(Qt6 REQUIRED NO_MODULE COMPONENTS
Core
Widgets
Gui
)

find_library(ff7tk ${CMAKE_CURRENT_BINARY_DIR}/src/data)
find_library(ff7tkQtWidgets ${CMAKE_CURRENT_BINARY_DIR}/src/widgets/common)

set ( ff7tkWidgets_SRC
AchievementEditor.cpp
CharEditor.cpp
ChocoboEditor.cpp
ChocoboLabel.cpp
ChocoboManager.cpp
ItemList.cpp
ItemListView.cpp
ItemPreview.cpp
ItemSelector.cpp
ItemSelectionDelegate.cpp
LocationViewer.cpp
MateriaEditor.cpp
MenuListWidget.cpp
MetadataCreator.cpp
OptionsWidget.cpp
PhsListWidget.cpp
SlotPreview.cpp
SlotSelect.cpp
)

set (ff7tkWidgets_HEADERS
AchievementEditor.h
ChocoboLabel.h
ItemSelector.h
ItemSelectionDelegate.h
MenuListWidget.h
PhsListWidget.h
CharEditor.h
ChocoboManager.h
ItemList.h
ItemListView.h
LocationViewer.h
MetadataCreator.h
SlotPreview.h
ChocoboEditor.h
ItemPreview.h
MateriaEditor.h
OptionsWidget.h
SlotSelect.h
${CMAKE_CURRENT_BINARY_DIR}/ff7tkwidgets_export.h
)

set( ff7tkWidgets_PublicLIBLINKS
Qt::Core
Qt::Widgets
Qt::Gui
ff7tk::ff7tk
ff7tk::ff7tkQtWidgets
)

MAKE_LIBRARY(ff7tkWidgets ff7tk/widgets/data)
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
9 changes: 9 additions & 0 deletions src/widgets/data/ff7tkWidgetsConfig.cmake.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
@PACKAGE_INIT@

include(CMakeFindDependencyMacro)
find_dependency(Qt6 "@REQUIRED_QT_VERSION@" COMPONENTS
Core
Gui
Widgets
)
include("${CMAKE_CURRENT_LIST_DIR}/ff7tkTargets.cmake")

0 comments on commit 91d9337

Please sign in to comment.