Skip to content
This repository has been archived by the owner on Apr 18, 2023. It is now read-only.

Commit

Permalink
nagbar: Remove i3-nagbar.h
Browse files Browse the repository at this point in the history
  • Loading branch information
orestisfl committed Apr 20, 2020
1 parent 0b62129 commit 2954125
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 29 deletions.
1 change: 0 additions & 1 deletion Makefile.am
Expand Up @@ -379,7 +379,6 @@ i3_nagbar_i3_nagbar_LDADD = \

i3_nagbar_i3_nagbar_SOURCES = \
i3-nagbar/atoms.xmacro \
i3-nagbar/i3-nagbar.h \
i3-nagbar/main.c

i3bar_i3bar_CPPFLAGS = \
Expand Down
1 change: 1 addition & 0 deletions i3-config-wizard/main.c
Expand Up @@ -9,6 +9,7 @@
*
*/
#include <config.h>
#include "libi3.h"

#include "libi3.h"

Expand Down
18 changes: 0 additions & 18 deletions i3-nagbar/i3-nagbar.h

This file was deleted.

22 changes: 12 additions & 10 deletions i3-nagbar/main.c
Expand Up @@ -8,15 +8,15 @@
* when the user has an error in their configuration file.
*
*/
#include <config.h>
#include "libi3.h"

#include <err.h>
#include <errno.h>
#include <fcntl.h>
#include <getopt.h>
#include <limits.h>
#include <paths.h>
#include <stdbool.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/stat.h>
Expand All @@ -28,14 +28,10 @@
#include <xcb/xcb.h>
#include <xcb/xcb_aux.h>
#include <xcb/xcb_cursor.h>
#include <xcb/xcb_event.h>

xcb_visualtype_t *visual_type = NULL;
#include "libi3.h"

#define SN_API_NOT_YET_FROZEN 1
#include "i3-nagbar.h"

#include <libsn/sn-launchee.h>

#define MSG_PADDING logical_px(8)
Expand All @@ -45,6 +41,12 @@ xcb_visualtype_t *visual_type = NULL;
#define CLOSE_BTN_GAP logical_px(15)
#define BAR_BORDER logical_px(2)

#define xmacro(atom) xcb_atom_t A_##atom;
#include "atoms.xmacro"
#undef xmacro

#define die(...) errx(EXIT_FAILURE, __VA_ARGS__);

static char *argv0 = NULL;

typedef struct {
Expand Down Expand Up @@ -314,8 +316,8 @@ static xcb_rectangle_t get_window_position(void) {
goto free_resources;

free_resources:
FREE(res);
FREE(primary);
free(res);
free(primary);
return result;
}

Expand Down Expand Up @@ -598,7 +600,7 @@ int main(int argc, char *argv[]) {
free(event);
}

FREE(pattern);
free(pattern);
draw_util_surface_free(conn, &bar);

return 0;
Expand Down

0 comments on commit 2954125

Please sign in to comment.