summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJérémie Courrèges-Anglas <jca@wxcvbn.org>2017-09-18 04:47:20 +0200
committerJérémie Courrèges-Anglas <jca@wxcvbn.org>2017-09-18 04:47:40 +0200
commitb57eea978b752cd347ecccfa76ea6333501af513 (patch)
tree8ea8333436a2c45dce61caae903fb3f7fa36ea09
parent1f8a8e447530376cae591029c6b8c523c9eab123 (diff)
downloadratpoison-b57eea978b752cd347ecccfa76ea6333501af513.zip
Delete more unused code
-rw-r--r--src/frame.c24
-rw-r--r--src/frame.h4
-rw-r--r--src/history.h1
-rw-r--r--src/manage.c37
-rw-r--r--src/manage.h2
-rw-r--r--src/window.c52
-rw-r--r--src/window.h6
7 files changed, 0 insertions, 126 deletions
diff --git a/src/frame.c b/src/frame.c
index 95e4952..9ba7178 100644
--- a/src/frame.c
+++ b/src/frame.c
@@ -112,30 +112,6 @@ frame_resize_down (rp_frame *frame, int amount)
frame->height += amount;
}
-void
-frame_move_left (rp_frame *frame, int amount)
-{
- frame->x -= amount;
-}
-
-void
-frame_move_right (rp_frame *frame, int amount)
-{
- frame->x += amount;
-}
-
-void
-frame_move_up (rp_frame *frame, int amount)
-{
- frame->y -= amount;
-}
-
-void
-frame_move_down (rp_frame *frame, int amount)
-{
- frame->y += amount;
-}
-
static void
init_frame (rp_frame *f)
{
diff --git a/src/frame.h b/src/frame.h
index f78f86c..293e9b9 100644
--- a/src/frame.h
+++ b/src/frame.h
@@ -21,10 +21,6 @@
#ifndef FRAME_H
#define FRAME_H
-void frame_move_down (rp_frame *frame, int amount);
-void frame_move_up (rp_frame *frame, int amount);
-void frame_move_right (rp_frame *frame, int amount);
-void frame_move_left (rp_frame *frame, int amount);
void frame_resize_down (rp_frame *frame, int amount);
void frame_resize_up (rp_frame *frame, int amount);
void frame_resize_right (rp_frame *frame, int amount);
diff --git a/src/history.h b/src/history.h
index 193874d..ee8430c 100644
--- a/src/history.h
+++ b/src/history.h
@@ -35,7 +35,6 @@ ssize_t getline (char **lineptr, size_t *n, FILE *f);
void history_load (void);
void history_save (void);
-void history_resize (int size);
void history_reset (void);
void history_add (int, const char *item);
const char *history_next (int);
diff --git a/src/manage.c b/src/manage.c
index 1440fab..510f730 100644
--- a/src/manage.c
+++ b/src/manage.c
@@ -327,26 +327,6 @@ update_window_name (rp_window *win)
return changed;
}
-/* Send an artificial configure event to the window. */
-void
-send_configure (Window w, int x, int y, int width, int height, int border)
-{
- XConfigureEvent ce;
-
- ce.type = ConfigureNotify;
- ce.event = w;
- ce.window = w;
- ce.x = x;
- ce.y = y;
- ce.width = width;
- ce.height = height;
- ce.border_width = border;
- ce.above = None;
- ce.override_redirect = 0;
-
- XSendEvent (dpy, w, False, StructureNotifyMask, (XEvent*)&ce);
-}
-
/* This function is used to determine if the window should be treated
as a transient. */
int
@@ -908,23 +888,6 @@ unhide_all_windows (void)
unhide_window (win);
}
-/* same as unhide_window except that it makes sure the window is mapped
- on the bottom of the window stack. */
-void
-unhide_window_below (rp_window *win)
-{
- if (win == NULL) return;
-
- /* Always lower the window, but if its not iconic we don't need to
- map it since it already is mapped. */
- XLowerWindow (dpy, win->w);
-
- if (win->state != IconicState) return;
-
- XMapWindow (dpy, win->w);
- set_state (win, NormalState);
-}
-
void
withdraw_window (rp_window *win)
{
diff --git a/src/manage.h b/src/manage.h
index 6788485..8001e09 100644
--- a/src/manage.h
+++ b/src/manage.h
@@ -33,7 +33,6 @@ void unmanage (rp_window *w);
int update_window_name (rp_window *win);
void update_normal_hints (rp_window *win);
void rename_current_window (void);
-void send_configure (Window w, int x, int y, int width, int height, int border);
void set_state (rp_window *win, int state);
long get_state (rp_window *win);
@@ -52,7 +51,6 @@ void grab_keys_all_wins (void);
void hide_window (rp_window *win);
void unhide_window (rp_window *win);
void unhide_all_windows (void);
-void unhide_window_below (rp_window *win);
void withdraw_window (rp_window *win);
void hide_others (rp_window *win);
void hide_screen_windows (rp_screen *s);
diff --git a/src/window.c b/src/window.c
index 07df96b..dd65a93 100644
--- a/src/window.c
+++ b/src/window.c
@@ -263,12 +263,6 @@ find_window (Window w)
return win;
}
-void
-set_current_window (rp_window *win)
-{
- set_frames_window (current_frame(), win);
-}
-
rp_window *
find_window_number (int n)
{
@@ -310,58 +304,12 @@ find_window_name (char *name, int exact_match)
return NULL;
}
-/* Return the previous window in the list. Assumes window is in the
- mapped window list. */
-rp_window*
-find_window_prev (rp_window *w)
-{
- rp_window *cur;
-
- if (!w) return NULL;
-
- for (cur = list_prev_entry (w, &rp_mapped_window, node);
- cur != w;
- cur = list_prev_entry (cur, &rp_mapped_window, node))
- {
- if (!find_windows_frame (cur))
- {
- return cur;
- }
- }
-
- return NULL;
-}
-
-/* Return the next window in the list. Assumes window is in the mapped
- window list. */
-rp_window*
-find_window_next (rp_window *w)
-{
- rp_window *cur;
-
- if (!w) return NULL;
-
- for (cur = list_next_entry (w, &rp_mapped_window, node);
- cur != w;
- cur = list_next_entry (cur, &rp_mapped_window, node))
- {
- if (!find_windows_frame (cur))
- {
- return cur;
- }
- }
-
- return NULL;
-}
-
rp_window *
find_window_other (rp_screen *screen)
{
return group_last_window (rp_current_group, screen);
}
-
-
/* Assumes the list is sorted by increasing number. Inserts win into
to Right place to keep the list sorted. */
void
diff --git a/src/window.h b/src/window.h
index 644407d..f2c021e 100644
--- a/src/window.h
+++ b/src/window.h
@@ -34,7 +34,6 @@ void give_window_focus (rp_window *win, rp_window *last_win);
void set_active_window (rp_window *win);
void set_active_window_force (rp_window *win);
void goto_window (rp_window *win);
-void set_current_window (rp_window *win);
void update_window_gravity (rp_window *win);
char *window_name (rp_window *win);
@@ -42,12 +41,7 @@ char *window_name (rp_window *win);
rp_window *find_window_other (rp_screen *screen);
rp_window *find_window_by_number (int n);
rp_window *find_window_name (char *name, int exact_match);
-rp_window *find_window_prev (rp_window *w);
-rp_window *find_window_prev_with_frame (rp_window *w);
-rp_window *find_window_next (rp_window *w);
-rp_window *find_window_next_with_frame (rp_window *w);
rp_window *find_window_number (int n);
-void sort_window_list_by_number (void);
void insert_into_list (rp_window *win, struct list_head *list);