summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBardur Arantsson <bardur@scientician.net>2012-06-28 11:16:30 +0200
committerBardur Arantsson <bardur@scientician.net>2012-06-28 11:21:03 +0200
commitd37a1238a94362ebfdebfdc3daf662cd3ba714af (patch)
treed886275e6a6009114a67ae4f7bb3132e3cb3fdd9
parentf9ff5f7b2be06310695c08d9ee16650b5d54f414 (diff)
Remove #if 0'd code
-rw-r--r--src/carbon/Carbon.r10
-rw-r--r--src/main-crb.c55
-rw-r--r--src/main-gtk2.c95
-rw-r--r--src/main-win.c37
-rw-r--r--src/main-xaw.c8
5 files changed, 0 insertions, 205 deletions
diff --git a/src/carbon/Carbon.r b/src/carbon/Carbon.r
index e3194dd2..9c1d412d 100644
--- a/src/carbon/Carbon.r
+++ b/src/carbon/Carbon.r
@@ -258,16 +258,6 @@ resource 'MENU' (129, preload)
/* its contents */
{
-#if 0
- /* item #1 */
- "New", noicon, "N", nomark, plain;
-
- /* item #2 */
- "Open", noicon, "O", nomark, plain;
-
- /* item #3 */
- "Import", noicon, "I", nomark, plain;
-#endif
/* item #1 (was #4) */
"Close", noicon, "W", nomark, plain;
diff --git a/src/main-crb.c b/src/main-crb.c
index 6defe9f2..c6a3a412 100644
--- a/src/main-crb.c
+++ b/src/main-crb.c
@@ -3119,13 +3119,6 @@ static void term_data_link(int i)
td->t->text_hook = Term_text_mac;
td->t->pict_hook = Term_pict_mac;
-#if 0
-
- /* Doesn't make big difference? */
- td->t->never_bored = TRUE;
-
-#endif
-
/* Link the local structure */
td->t->data = (void *)(td);
@@ -3445,25 +3438,6 @@ static void cf_load_prefs()
return;
}
-#if 0
-
- /* Check version */
- if ((pref_major != PREF_VER_MAJOR) ||
- (pref_minor != PREF_VER_MINOR) ||
- (pref_patch != PREF_VER_PATCH) ||
- (pref_extra != PREF_VER_EXTRA))
- {
- /* Message */
- mac_warning(
- format("Ignoring %d.%d.%d.%d preferences.",
- pref_major, pref_minor, pref_patch, pref_extra));
-
- /* Ignore */
- return;
- }
-
-#endif
-
/* Gfx settings */
{
short pref_tmp;
@@ -5161,19 +5135,6 @@ static bool_ CheckEvents(bool_ wait)
switch (event.what)
{
-#if 0
-
- case activateEvt:
- {
- w = (WindowPtr)event.message;
-
- activate(w);
-
- break;
- }
-
-#endif
-
case updateEvt:
{
/* Extract the window */
@@ -5494,13 +5455,6 @@ static bool_ CheckEvents(bool_ wait)
/* Handle "quit_when_ready" */
if (quit_when_ready)
{
-#if 0 /* Doesn't work with Aqua well */
- /* Forget */
- quit_when_ready = FALSE;
-
- /* Do the menu key */
- menu(MenuKey('q'));
-#endif
/* Turn off the menus */
HiliteMenu(0);
}
@@ -5766,19 +5720,10 @@ static void init_stuff(void)
/* Display location */
dialogOptions.location = topleft;
-#if 0
-
- /* Load the message for the missing folder from the resource fork */
- /* GetIndString(dialogOptions.message, 128, 1); */
-
-#else
-
/* Set the message for the missing folder XXX XXX */
strcpy(dialogOptions.message + 1, "Please select the \"lib\" folder");
dialogOptions.message[0] = strlen(dialogOptions.message + 1);
-#endif
-
/* Wait for the user to choose a folder */
err = NavChooseFolder(
nil, &theReply, &dialogOptions, nil, nil, nil);
diff --git a/src/main-gtk2.c b/src/main-gtk2.c
index 0a14787c..102a8b7b 100644
--- a/src/main-gtk2.c
+++ b/src/main-gtk2.c
@@ -169,36 +169,6 @@ if ((td)->backing_store) gdk_draw_pixmap( \
(hgt) * (td)->font_hgt)
-#if 0
-
-/* Compile time option version */
-
-# ifdef USE_BACKING_STORE
-
-# define TERM_DATA_DRAWABLE(td) (td)->backing_store
-
-# define TERM_DATA_REFRESH(td, x, y, wid, hgt) \
-gdk_draw_pixmap( \
-(td)->drawing_area->window, \
-(td)->gc, \
-(td)->backing_store, \
-(x) * (td)->font_wid, \
-(y) * (td)->font_hgt, \
-(x) * (td)->font_wid, \
-(y) * (td)->font_hgt, \
-(wid) * (td)->font_wid, \
-(hgt) * (td)->font_hgt)
-
-# else /* USE_BACKING_STORE */
-
-# define TERM_DATA_DRAWABLE(td) (td)->drawing_area->window
-# define TERM_DATA_REFRESH(td, x, y, wid, hgt)
-
-# endif /* USE_BACKING_STORE */
-
-#endif /* 0 */
-
-
/*
* An array of "term_data" structures, one for each "sub-window"
*/
@@ -498,41 +468,6 @@ static void gdk_rgb_image_destroy(
}
-#if 0
-
-/*
- * Unref a GdkRGBImage
- */
-static void gdk_rgb_image_unref(
- GdkRGBImage *im)
-{
- /* Paranoia */
- g_return_if_fail(im != NULL);
-
- /* Decrease reference count by 1 */
- im->ref_count--;
-
- /* Free if nobody's using it */
- if (im->ref_count <= 0) gdk_rgb_image_destroy(im);
-}
-
-
-/*
- * Reference a GdkRGBImage
- */
-static void gdk_rgb_image_ref(
- GdkRGBImage *im)
-{
- /* Paranoia */
- g_return_if_fail(im != NULL);
-
- /* Increase reference count by 1 */
- im->ref_count++;
-}
-
-#endif /* 0 */
-
-
/*
* Write RGB pixel of the format 0xRRGGBB to (x, y) in GdkRGBImage
*/
@@ -1107,36 +1042,6 @@ static void copy_pixels(
}
-#if 0
-
-/* 32-bit version: it might be useful in the future */
-static void copy_pixels(
- int wid,
- int y,
- int offset,
- int *xoffsets,
- GdkRGBImage *old_image,
- GdkRGBImage *new_image)
-{
- int i;
-
- /* Get source and destination */
- byte *src = &old_image->image[offset * old_image->width * 4];
- byte *dst = &new_image->image[y * new_image->width * 4];
-
- /* Copy to the image */
- for (i = 0; i < wid; i++)
- {
- *dst++ = src[4 * xoffsets[i]];
- *dst++ = src[4 * xoffsets[i] + 1];
- *dst++ = src[4 * xoffsets[i] + 2];
- *dst++ = src[4 * xoffsets[i] + 3];
- }
-}
-
-#endif
-
-
/*
* Resize ix * iy pixel tiles in old to ox * oy pixels
* and return a new GdkRGBImage containing the resized tiles
diff --git a/src/main-win.c b/src/main-win.c
index a618de96..2d740034 100644
--- a/src/main-win.c
+++ b/src/main-win.c
@@ -1444,28 +1444,6 @@ static void term_data_redraw(term_data *td)
/*** Function hooks needed by "Term" ***/
-#if 0
-
-/*
- * Initialize a new Term
- */
-static void Term_init_win(term *t)
-{
- /* XXX Unused */
-}
-
-
-/*
- * Nuke an old Term
- */
-static void Term_nuke_win(term *t)
-{
- /* XXX Unused */
-}
-
-#endif
-
-
/*
* Interact with the User
*/
@@ -2247,12 +2225,6 @@ static void term_data_link(term_data *td)
t->attr_blank = TERM_WHITE;
t->char_blank = ' ';
-#if 0
- /* Prepare the init/nuke hooks */
- t->init_hook = Term_init_win;
- t->nuke_hook = Term_nuke_win;
-#endif
-
/* Prepare the template hooks */
t->user_hook = Term_user_win;
t->xtra_hook = Term_xtra_win;
@@ -3726,15 +3698,6 @@ WPARAM wParam, LPARAM lParam)
return 0;
}
-#if 0
- case WM_ACTIVATE:
- {
- if (LOWORD(wParam) == WA_INACTIVE) break;
-
- /* else fall through */
- }
-#endif
-
case WM_LBUTTONDOWN:
case WM_MBUTTONDOWN:
case WM_RBUTTONDOWN:
diff --git a/src/main-xaw.c b/src/main-xaw.c
index 8795e00d..8de36a95 100644
--- a/src/main-xaw.c
+++ b/src/main-xaw.c
@@ -852,14 +852,6 @@ static void Redisplay(AngbandWidget wnew, XEvent *xev, Region region)
/* Activate the old term */
Term_activate(&old_td->t);
-
-
-#if 0
- if (XtHasCallbacks((Widget)widget, XtNredrawCallback) == XtCallbackHasSome)
- {
- XtCallCallbacks((Widget)widget, XtNredrawCallback, NULL);
- }
-#endif /* 0 */
}