Skip to content

Commit 99c7bd7

Browse files
committed
Removing remaining modification from CMakefileLists.txt,
fixing error message for unknown border style: "W: Got a unknown "border" property: "pixel". Perhaps its neccessary to update i3ipc++. If you are using latest, note maintainer about this" caused by setting "new window pixel 1" in the i3config."
1 parent 029d22a commit 99c7bd7

File tree

3 files changed

+5
-20
lines changed

3 files changed

+5
-20
lines changed

CMakeLists.txt

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ project(i3ipc++)
33

44
option(I3IPCpp_WITH_TESTS "Build unit tests executables" OFF)
55
option(I3IPCpp_BUILD_EXAMPLES "Build example executables" OFF)
6-
option(I3IPCpp_USE_FULL_SIGNALS "Provide full JSON event object with the signals for workspace_event and window_event. !!CHANGES API!!" OFF)
76

87
set(BUILD_STATIC_LIBS ON)
98
set(BUILD_SHARED_LIBS OFF)
@@ -14,14 +13,7 @@ UNSET(BUILD_SHARED_LIBS)
1413
find_package(PkgConfig)
1514
pkg_check_modules(SIGCPP REQUIRED sigc++-2.0)
1615

17-
# configure a header file to pass some settings to the source code
18-
configure_file (
19-
"${PROJECT_SOURCE_DIR}/include/i3ipc++/i3ipc++_config.hpp.in"
20-
"${PROJECT_BINARY_DIR}/include/i3ipc++_config.hpp"
21-
)
22-
2316
include_directories(
24-
${PROJECT_BINARY_DIR}/include
2517
${SIGCPP_INCLUDE_DIRS}
2618
3rd/jsoncpp/include
2719
3rd/auss/include
@@ -49,8 +41,7 @@ set(I3IPCpp_INCLUDE_DIRS
4941
set(I3IPCpp_LIBRARIES i3ipc++_static ${SIGCPP_LIBRARIES} jsoncpp_lib_static)
5042

5143
set(I3IPCpp_LIBRARY_DIRS ${I3IPCpp_LIBRARY_DIRS} PARENT_SCOPE)
52-
set(I3IPCpp_INCLUDE_DIRS ${I3IPCpp_INCLUDE_DIRS})
53-
set(I3IPCpp_INCLUDE_DIRS ${I3IPCpp_INCLUDE_DIRS} ${PROJECT_BINARY_DIR}/include PARENT_SCOPE)
44+
set(I3IPCpp_INCLUDE_DIRS ${I3IPCpp_INCLUDE_DIRS} PARENT_SCOPE)
5445
set(I3IPCpp_LIBRARIES ${I3IPCpp_LIBRARIES} PARENT_SCOPE)
5546

5647
if(I3IPCpp_BUILD_EXAMPLES)

include/i3ipc++/ipc.hpp

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,6 @@
55
#include <memory>
66
#include <vector>
77

8-
#include "i3ipc++_config.hpp"
9-
10-
#ifdef I3IPCpp_USE_FULL_SIGNALS
11-
#include <json/json.h>
12-
#endif
13-
148
#include <sigc++/sigc++.h>
159

1610
extern "C" {
@@ -85,7 +79,6 @@ enum EventType {
8579
ET_BARCONFIG_UPDATE = (1 << 4), ///< Bar config update event @attention Yet is not implemented as signal in connection
8680
};
8781

88-
#ifndef I3IPCpp_USE_FULL_SIGNALS
8982
/**
9083
* Types of workspace events
9184
*/
@@ -118,6 +111,7 @@ enum class BorderStyle : char {
118111
UNKNOWN = '?', //< If got an unknown border style in reply
119112
NONE = 'N',
120113
NORMAL = 'n',
114+
PIXEL = 'P',
121115
ONE_PIXEL = '1',
122116
};
123117

@@ -159,7 +153,6 @@ struct container_t {
159153

160154
std::list< std::shared_ptr<container_t> > nodes;
161155
};
162-
#endif
163156

164157

165158
/**

src/ipc.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,7 @@
44
#include <iostream>
55

66
#include <auss.hpp>
7-
#ifndef I3IPCpp_USE_FULL_SIGNALS
87
#include <json/json.h>
9-
#endif
108

119
#include "log.hpp"
1210
#include "ipc-util.hpp"
@@ -78,6 +76,8 @@ static std::shared_ptr<container_t> parse_container_from_json(const Json::Value
7876
container->border = BorderStyle::NORMAL;
7977
} else if (border == "none") {
8078
container->border = BorderStyle::NONE;
79+
} else if (border == "pixel") {
80+
container->border = BorderStyle::PIXEL;
8181
} else if (border == "1pixel") {
8282
container->border = BorderStyle::ONE_PIXEL;
8383
} else {
@@ -178,6 +178,7 @@ std::string get_socketpath() {
178178
return str;
179179
}
180180

181+
181182
connection::connection(const std::string& socket_path) : m_main_socket(i3_connect(socket_path)), m_event_socket(-1), m_subscriptions(0), m_socket_path(socket_path) {
182183
#define i3IPC_TYPE_STR "i3's event"
183184
signal_event.connect([this](EventType event_type, const std::shared_ptr<const buf_t>& buf) {

0 commit comments

Comments
 (0)