summaryrefslogtreecommitdiff
path: root/oldslashapp
diff options
context:
space:
mode:
authorJacob Berkman <jberkman@src.gnome.org>2000-09-26 22:49:07 +0000
committerJacob Berkman <jberkman@src.gnome.org>2000-09-26 22:49:07 +0000
commit7703c8fb0e90fe84aa1b89cca6838b8d28f7c33d (patch)
tree78e9646e5f92a68f0eaa370631b2c8cf8812e193 /oldslashapp
parentfdf04506fa3556e038ab311a3d8c03f64e86d6eb (diff)
removing old directories
Diffstat (limited to 'oldslashapp')
-rw-r--r--oldslashapp/.cvsignore5
-rw-r--r--oldslashapp/AUTHORS5
-rw-r--r--oldslashapp/BUGS2
-rw-r--r--oldslashapp/ChangeLog108
-rw-r--r--oldslashapp/Makefile.am25
-rw-r--r--oldslashapp/THIS_APPLET_IS_DEAD0
-rw-r--r--oldslashapp/back.xpm49
-rw-r--r--oldslashapp/display.c641
-rw-r--r--oldslashapp/http_get.c154
-rw-r--r--oldslashapp/http_get.h11
-rw-r--r--oldslashapp/noimage.xpm27
-rw-r--r--oldslashapp/properties.c431
-rw-r--r--oldslashapp/slash_applet.desktop46
-rw-r--r--oldslashapp/slash_applet.gnorba5
-rw-r--r--oldslashapp/slashapp.c690
-rw-r--r--oldslashapp/slashapp.h153
-rw-r--r--oldslashapp/slashsplash.gifbin15559 -> 0 bytes
-rw-r--r--oldslashapp/slashsplash.xpm75
18 files changed, 0 insertions, 2427 deletions
diff --git a/oldslashapp/.cvsignore b/oldslashapp/.cvsignore
deleted file mode 100644
index b759e0597..000000000
--- a/oldslashapp/.cvsignore
+++ /dev/null
@@ -1,5 +0,0 @@
-Makefile.in
-Makefile
-.deps
-.libs
-slash_applet
diff --git a/oldslashapp/AUTHORS b/oldslashapp/AUTHORS
deleted file mode 100644
index fc2fe7827..000000000
--- a/oldslashapp/AUTHORS
+++ /dev/null
@@ -1,5 +0,0 @@
-Justin Maurer - <justin@openprojects.net>
-John Ellis - <johne@bellatlantic.net>
-Frederic Devernay <devernay@istar.fr>
-Craig Small - <csmall@eye-net.com.au>
-
diff --git a/oldslashapp/BUGS b/oldslashapp/BUGS
deleted file mode 100644
index de94ba8cf..000000000
--- a/oldslashapp/BUGS
+++ /dev/null
@@ -1,2 +0,0 @@
-* Why the hell does it make the panel unusable? That defeats the purpose of
- using gnome-http
diff --git a/oldslashapp/ChangeLog b/oldslashapp/ChangeLog
deleted file mode 100644
index 249585c9a..000000000
--- a/oldslashapp/ChangeLog
+++ /dev/null
@@ -1,108 +0,0 @@
-Sat Feb 20 23:28:45 1999 John Ellis <johne@bellatlantic.net>
-
- * properties.c(property_load): Using the same prefix for save and
- load of options is a good idea.
-
-Sun Dec 13 07:55:06 1998 John Ellis <johne@bellatlantic.net>
-
- * properties.c: Commented out the unused server entry widgets. Added
- a signal to update the apply button immediately when a spin_button
- value is changed by manually typing the value.
-
-1998-12-11 James Henstridge <james@daa.com.au>
-
- * properties.c (property_show): #ifdef'd out section on configuration
- of what browser to use. This is now handled by the url-properties
- capplet.
-
- * slashapp.c: Altered to use the gnome_url_show, and #ifdef'd out the
- old launch_url implementation. Also changed an occurence of
- gtk_container_add to gtk_scrolled_window_add_with_viewport, where it
- was needed.
-
-1998-11-29 Jeff Garzik <jgarzik@pobox.com>
-
- * slashapp.c:
- Added required app id arg to applet_widget_new.
-
-1998-11-11 Christopher Blizzard <blizzard@appliedtheory.com>
-
- * slashapp.c: Apply patches forwarded by Justin Maurer
- <justin@openprojects.net> from Frederic Devernay
- <devernay@istar.fr> to make slashapp use gnome-http.
-
-Mon Nov 9 21:10:24 1998 John Ellis <johne@bellatlantic.net>
-
- * slashapp.c(get_topic_image), (delete_if_empty): Fixes to avoid
- blank window and errors when loading an image fails.
-
-Thu Oct 15 19:10:33 1998 Justin Maurer <justin@openprojects.net>
-
- * slashapp.c: Edited some messages (i.e, nothing large),
- !!!commented!!! out the gdk cursor stuff to see if it would stop
- locking the panel - NOTE: i cannot test this. if it breaks, just
- uncomment the two lines around line 323 in slashapp.c
-
-Fri Oct 2 19:43:06 1998 John Ellis <johne@bellatlantic.net>
-
- * slashapp.[ch]: Added dialog to list all articles, called from the
- right click menu. Removed debug printf's.
- * display.c: Minor change to ensure an initial NULL pointer.
-
-Tue Sep 29 17:02:31 1998 John Ellis <johne@bellatlantic.net>
-
- * slashapp.[ch], properties.c: Allow configuration of delay between
- articles. Minor display formatting changes.
- * properties.c: Map out ability to specify the article server.
-
-Tue Sep 29 15:36:53 1998 John Ellis <johne@bellatlantic.net>
-
- * slashapp.[ch]: Show a wait curser when downloading headlines.
- * display.c(free_info_line): Include freeing of related ClickData *.
-
-Tue Sep 29 14:51:12 1998 John Ellis <johne@bellatlantic.net>
-
- * slashapp.[ch], display.c: Now clicking on a headline will launch
- netscape with that headline.
- * properties.c: Added option to display headline in a new window.
-
-Mon Sep 28 19:39:14 1998 John Ellis <johne@bellatlantic.net>
-
- * slashapp.[ch], properties.c: Images, department, extra info is now
- optional. Info includes # of comments now, too.
-
-Mon Sep 28 18:12:57 1998 John Ellis <johne@bellatlantic.net>
-
- * slashapp.[ch], display.c: Added loading of topic images some images
- are broken however because some topics do not have a corresponding
- exact filename match on the server. Hmm.
- * Makefile.am: Added slashsplash.xpm to extra-dist.
-
-Mon Sep 28 12:07:57 1998 John Ellis <johne@bellatlantic.net>
-
- * slashapp.[ch], display.c, properties.c: Slash app has a new display
- engine. It is actually useable now :)
- * back.xpm, noimage.xpm:Image files for the display engine.
- * Makefile.am: Some cleanup, it might work now?
-
-Version 0.3
------------
-John Ellis <johne@bellatlantic.net>
- - Major display engine changes.
-
-Version 0.2
------------
-Justin Maurer <mike911@clark.net>
- - Various cleanups and small bugfixes (Craig gets most of the credit
- for this one!)
-
-Craig Small <csmall@small.dropbear.co.uk>
- - Changed (for the better) headlines from labels to text
- - Rewrote ultramode parser - kudos!
- - Redid slashsplash.gif
-
-Version 0.1
------------
-Justin Maurer <mike911@clark.net>
- - Initial release. Code glued together from many files,
- breaking many functions.
diff --git a/oldslashapp/Makefile.am b/oldslashapp/Makefile.am
deleted file mode 100644
index 0142f6457..000000000
--- a/oldslashapp/Makefile.am
+++ /dev/null
@@ -1,25 +0,0 @@
-INCLUDES = -I. -I$(srcdir) \
- -DGNOMELOCALEDIR=\""$(datadir)/locale"\" \
- -I$(includedir) $(GNOME_INCLUDEDIR)
-
-bin_PROGRAMS = slash_applet
-
-slash_applet_SOURCES = slashapp.c \
- slashapp.h \
- display.c \
- properties.c
-
-slash_applet_LDADD = \
- $(GNOME_LIBDIR) -lXt \
- $(GNOME_APPLETS_LIBS) $(INTLLIBS) \
- $(GHTTP_LIB)
-
-EXTRA_DIST = \
- slash_applet.desktop back.xpm noimage.xpm slashsplash.xpm \
- slash_applet.gnorba
-
-sysdir = $(datadir)/applets/Amusements
-sys_DATA = slash_applet.desktop
-
-gnorbadir = $(sysconfdir)/CORBA/servers
-gnorba_DATA = slash_applet.gnorba
diff --git a/oldslashapp/THIS_APPLET_IS_DEAD b/oldslashapp/THIS_APPLET_IS_DEAD
deleted file mode 100644
index e69de29bb..000000000
--- a/oldslashapp/THIS_APPLET_IS_DEAD
+++ /dev/null
diff --git a/oldslashapp/back.xpm b/oldslashapp/back.xpm
deleted file mode 100644
index 6fa0b81f0..000000000
--- a/oldslashapp/back.xpm
+++ /dev/null
@@ -1,49 +0,0 @@
-/* XPM */
-static char * back_xpm[] = {
-"240 44 2 1",
-" c None",
-". c #FFFFFF",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................",
-"................................................................................................................................................................................................................................................"};
diff --git a/oldslashapp/display.c b/oldslashapp/display.c
deleted file mode 100644
index e533b9852..000000000
--- a/oldslashapp/display.c
+++ /dev/null
@@ -1,641 +0,0 @@
-/*###################################################################*/
-/*## ##*/
-/*###################################################################*/
-
-#include "slashapp.h"
-#include "back.xpm"
-#include "noimage.xpm"
-
-static InfoData *create_info_line(gchar *text, gchar *icon_path, GtkWidget *icon,
- gint offset, gint center, gint show_count, gint delay);
-static void free_info_line(AppData *ad, InfoData *id);
-static gint check_info_for_removal(AppData *ad, InfoData *id);
-static GList *next_info_line(AppData *ad);
-static void redraw_display(AppData *ad);
-static void draw_pixmap(AppData *ad, GdkPixmap *smap, GdkPixmap *tmap, gint x, gint y, gint w, gint h, gint xo, gint yo);
-static void scroll_display_up(AppData *ad, gint m);
-static void draw_display_line(AppData *ad);
-static gint update_display_cb(gpointer data);
-static void register_click_func(AppData *ad, InfoData *id);
-static void scroll_click_func(AppData *ad, gint m);
-static int display_click(GtkWidget *w, GdkEventButton *event, gpointer data);
-static void display_motion(GtkWidget *w, GdkEventMotion *event, gpointer data);
-
-static InfoData *create_info_line(gchar *text, gchar *icon_path, GtkWidget *icon,
- gint offset, gint center, gint show_count, gint delay)
-{
- InfoData *id;
- if (!text) return NULL;
- id = g_new0(InfoData, 1);
-
- id->click_func = NULL;
- id->data = NULL;
- id->free_func = NULL;
-
- id->text = g_strdup(text);
-
- if (icon_path)
- id->icon_path = g_strdup(icon_path);
- else
- id->icon_path = NULL;
-
- if (icon)
- {
- gint width, height;
- id->icon = icon;
- gdk_window_get_size (GNOME_PIXMAP(id->icon)->pixmap, &width, &height);
- id->icon_w = width;
- id->icon_h = height;
- }
- else
- {
- id->icon = NULL;
- id->icon_w = 0;
- id->icon_h = 0;
- }
-
- id->length = strlen(text);
-
- if (id->icon_w == 0 || offset > id->icon_w + 4)
- id->offset = offset;
- else
- {
- if (id->icon_w > 0)
- id->offset = id->icon_w + 4;
- else
- id->offset = 0;
- }
-
- id->center = center;
-
- id->shown = FALSE;
- id->show_count = show_count;
-
- id->end_delay = delay;
-
- return id;
-}
-
-static void free_info_line(AppData *ad, InfoData *id)
-{
- GList *list = ad->click_list;
-
- if (!id) return;
-
- while(list)
- {
- GList *w = list;
- ClickData *cd = w->data;
- list = list->next;
-
- if (cd->line_id == id)
- {
- ad->click_list = g_list_remove(ad->click_list, cd);
- g_free(cd);
- }
- }
-
- g_free(id->text);
- g_free(id->icon_path);
-
- if (id->icon) gtk_widget_destroy(id->icon);
-
- if (id->data && id->free_func) id->free_func(id->data);
-
- g_free(id);
-}
-
-void free_all_info_lines(AppData *ad)
-{
- GList *list = ad->text;
-
- if (!list) return;
- while(list)
- {
- InfoData *id = list->data;
- free_info_line(ad, id);
- list = list->next;
- }
- g_list_free(ad->text);
- ad->text = NULL;
-}
-
-InfoData *add_info_line(AppData *ad, gchar *text, gchar *icon_path, gint offset, gint center,
- gint show_count, gint delay)
-{
- InfoData *id;
- GtkWidget *icon = NULL;
-
- if (icon_path)
- {
- if (g_file_exists(icon_path))
- icon = gnome_pixmap_new_from_file(icon_path);
- if (!icon)
- icon = gnome_pixmap_new_from_xpm_d(noimage_xpm);
- }
-
- id = create_info_line(text, icon_path, icon, offset, center, show_count, delay);
- if (id)
- {
- ad->text = g_list_append(ad->text, id);
- ad->text_lines++;
- }
-
- return id;
-}
-
-InfoData *add_info_line_with_pixmap(AppData *ad, gchar *text, GtkWidget *icon, gint offset, gint center,
- gint show_count, gint delay)
-{
- InfoData *id;
- id = create_info_line(text, NULL, icon, offset, center, show_count, delay);
- if (id)
- {
- ad->text = g_list_append(ad->text, id);
- ad->text_lines++;
- }
-
- return id;
-}
-
-void remove_info_line(AppData *ad, InfoData *id)
-{
- if (!id) return;
- if (ad->current_text && ad->current_text->data == id)
- {
- /* if current line is being displayed, schedule to remove */
- id->show_count = 1;
- }
- else
- {
- ad->text = g_list_remove(ad->text, id);
- free_info_line(ad, id);
- ad->text_lines--;
- }
-}
-
-void remove_all_lines(AppData *ad)
-{
- GList *list;
-
- list = ad->text;
- while (list)
- {
- InfoData *id = list->data;
- list = list->next;
- remove_info_line(ad, id);
- }
-}
-
-void set_info_click_signal(InfoData *id, void (*click_func)(AppData *ad, gpointer data),
- gpointer data, void (*free_func)(gpointer data))
-{
- if (!id) return;
- id->click_func = click_func;
- id->data = data;
- id->free_func = free_func;
-}
-
-static gint check_info_for_removal(AppData *ad, InfoData *id)
-{
- if (id->show_count > 0)
- {
- id->show_count--;
- if (id->show_count == 0)
- {
- remove_info_line(ad, id);
- if (!ad->text)
- {
- ad->current_text = NULL;
- return TRUE;
- }
- }
- }
- return FALSE;
-}
-
-static GList *next_info_line(AppData *ad)
-{
- GList *list = ad->text;
-
- /* check for the first unshown info item, they have priority*/
- while(list)
- {
- InfoData *id = list->data;
- if (!id->shown) return list;
- list = list->next;
- }
-
- /* all have been shown, just return the next line */
- list = ad->current_text->next;
- if (!list) list = ad->text;
- return list;
-}
-
-static void redraw_display(AppData *ad)
-{
- gdk_window_set_back_pixmap(ad->draw_area->window,ad->display,FALSE);
- gdk_window_clear(ad->draw_area->window);
-}
-
-static void draw_pixmap(AppData *ad, GdkPixmap *smap, GdkPixmap *tmap, gint x, gint y, gint w, gint h, gint xo, gint yo)
-{
- gdk_draw_pixmap(tmap,
- ad->draw_area->style->fg_gc[GTK_WIDGET_STATE(ad->draw_area)],
- smap, xo, yo, x, y, w, h);
-}
-
-static void scroll_display_up(AppData *ad, gint m)
-{
- draw_pixmap (ad, ad->display, ad->disp_buf, 0, 0, ad->width, ad->height - m, 0, m);
- draw_pixmap (ad, ad->disp_buf, ad->display, 0, 0, ad->width, ad->height - m, 0, 0);
- draw_pixmap (ad, ad->background, ad->display, 0, ad->height - m, ad->width, m, 0, ad->height - m);
- if (ad->current_text)
- {
- InfoData *id = ad->current_text->data;
- if (id->icon && id->icon_h > ad->current_line_pos * ad->scroll_height)
- {
- gint x,y;
- gint xo, yo;
- gint w, h;
-
- x = 2;
- y = ad->height - m;
- xo = 0;
- if (m == ad->scroll_height)
- yo = ad->current_line_pos * ad->scroll_height;
- else
- yo = (ad->current_line_pos * ad->scroll_height) + ad->scroll_height - ad->scroll_pos;
- w = id->icon_w;
- h = m;
- if (h + yo > id->icon_h) h = id->icon_h - yo;
- if (yo < id->icon_h && h > 0)
- draw_pixmap (ad, GNOME_PIXMAP(id->icon)->pixmap, ad->display,
- x, y, w, h, xo, yo);
- }
- }
- redraw_display(ad);
- scroll_click_func(ad, m);
-}
-
-static void draw_display_line(AppData *ad)
-{
- InfoData *id;
- gint new_x_pos;
- gchar c;
- GdkFont *font;
-
- if (!ad->text) return;
- if (!ad->current_text) ad->current_text = ad->text;
- id = ad->current_text->data;
- if (!id) return;
-
- font = ad->draw_area->style->font;
-
- if (ad->new_line)
- {
- if (ad->text_pos > id->length)
- {
- GList *temp;
- if (id->icon && id->icon_h > ad->current_line_pos * ad->text_height)
- {
- ad->scroll_pos = ad->scroll_height;
- ad->current_line_pos ++;
- if (id->icon_h <= ad->current_line_pos * ad->text_height)
- ad->scroll_count = id->end_delay / 10 * (1000 / UPDATE_DELAY);
- return;
- }
- id->shown = TRUE;
- ad->text_pos = 0;
- temp = next_info_line(ad);
- ad->current_text = NULL;
- ad->current_line_pos = 0;
- check_info_for_removal(ad, id);
- if (!ad->text || !temp) return;
- ad->current_text = temp;
- id = ad->current_text->data;
- }
- ad->new_line = FALSE;
- ad->x_pos = 0;
- if (id->icon && id->icon_h > ad->current_line_pos * ad->text_height)
- {
- gint x,y;
- gint xo, yo;
- gint w, h;
- x = 2;
- y = ad->height - ad->text_height;
- xo = 0;
- yo = ad->current_line_pos * ad->text_height;
- w = id->icon_w;
- h = id->icon_h - (ad->current_line_pos * ad->text_height);
- draw_pixmap (ad, GNOME_PIXMAP(id->icon)->pixmap, ad->display, x, y, w, h, xo, yo);
- }
- if (id->center && !id->icon)
- {
- gint l = gdk_text_width(font, id->text, id->length);
- if (l < ad->width)
- {
- ad->x_pos = ( ad->width - l ) / 2;
- }
- else
- {
- ad->x_pos = id->offset;
- }
- }
- else
- ad->x_pos = id->offset;
-
- /* add the click check */
- if (id->click_func && ad->current_line_pos == 0)
- {
- register_click_func(ad, id);
- }
- }
-
- c = id->text[ad->text_pos];
- if (ad->x_pos == id->offset && c == ' ' &&
- ad->text_pos < id->length - 1 && id->text[ad->text_pos +1] != ' ')
- {
- ad->text_pos++;
- c = id->text[ad->text_pos];
- }
- new_x_pos = ad->x_pos + gdk_char_width (font, c);
-
- gdk_draw_text(ad->display, font,
- ad->draw_area->style->fg_gc[GTK_WIDGET_STATE(ad->draw_area)],
- ad->x_pos, ad->height - ad->text_y_line, id->text + ad->text_pos, 1);
-
- ad->text_pos ++;
- if (ad->text_pos > id->length)
- {
- ad->new_line = TRUE;
- }
- else
- {
- ad->x_pos = new_x_pos;
- c = id->text[ad->text_pos];
- if (ad->x_pos + gdk_char_width (font, c) > ad->width)
- {
- ad->new_line = TRUE;
- }
- else if (c == '\n')
- {
- ad->text_pos++;
- ad->new_line = TRUE;
- }
- else if (c == ' ' && ad->text_pos < id->length)
- {
- gint word_length;
- gint l = strlen(id->text);
- gint p;
- p = ad->text_pos + 1;
- while (p < l && id->text[p] != ' ' && id->text[p] != '\n') p++;
- word_length = gdk_text_width(font, id->text + ad->text_pos,
- p - ad->text_pos);
- if (ad->x_pos + word_length > ad->width)
- {
- ad->text_pos++;
- ad->new_line = TRUE;
- }
- }
- }
-
- if (ad->new_line)
- {
- ad->current_line_pos ++;
- ad->scroll_pos = ad->scroll_height;
-
- if (ad->text_pos > id->length)
- ad->scroll_count = id->end_delay / 10 * (1000 / UPDATE_DELAY);
- else
- ad->scroll_count = ad->scroll_delay / 10 * (1000 / UPDATE_DELAY);
-
- }
-}
-
-static gint update_display_cb(gpointer data)
-{
- AppData *ad = data;
- if (!ad) return FALSE;
-
- if (ad->scroll_count > 0)
- {
- ad->scroll_count --;
- return TRUE;
- }
-
- if (ad->new_line && ad->scroll_pos > 0)
- {
- /* draw the scrolling */
- if (ad->smooth_scroll)
- {
- gint s = ad->scroll_speed;
- if (ad->scroll_pos - s < 1) s = ad->scroll_pos - 1;
- scroll_display_up(ad, s);
- }
- else
- {
- if (ad->scroll_pos - ad->scroll_speed < 1)
- scroll_display_up(ad, ad->scroll_height);
- }
- ad->scroll_pos -= ad->scroll_speed;
- return TRUE;
- }
-
- if (ad->smooth_type)
- {
- draw_display_line(ad);
- redraw_display(ad);
- }
- else
- {
- draw_display_line(ad);
- while(!ad->new_line) draw_display_line(ad);
- redraw_display(ad);
- }
- return TRUE;
-}
-
-void set_mouse_cursor (AppData *ad, gint icon)
-{
- GdkCursor *cursor = gdk_cursor_new (icon);
- gdk_window_set_cursor (ad->draw_area->window, cursor);
- gdk_cursor_destroy (cursor);
-}
-
-static void register_click_func(AppData *ad, InfoData *id)
-{
- ClickData *cd;
-
- if (!id || !id->click_func) return;
-
- cd = g_new0(ClickData, 1);
-
- cd->line_id = id;
- cd->click_func = id->click_func;
- cd->data = id->data;
-
- cd->x = 0;
- cd->y = ad->height - ad->scroll_height;
- cd->w = ad->width;
- cd->h = ad->scroll_height;
-
- ad->click_list = g_list_append(ad->click_list, cd);
-
- scroll_click_func(ad, 0);
-}
-
-static void scroll_click_func(AppData *ad, gint m)
-{
- GList *list = ad->click_list;
- gint proximity = FALSE;
-
- while(list)
- {
- GList *w = list;
- ClickData *cd = w->data;
- list = list->next;
-
- cd->y -= m;
-
- if (ad->current_text)
- {
- InfoData *id = ad->current_text->data;
- if (id == cd->line_id && ad->text_pos <= id->length) cd->h += m;
- }
-
- if (cd->y + cd->h < 1)
- {
- ad->click_list = g_list_remove(ad->click_list, cd);
- g_free(cd);
- }
- else
- {
- GdkModifierType modmask;
- gint x, y;
- gdk_window_get_pointer (ad->draw_area->window, &x, &y, &modmask);
- if (x >= cd->x && x < cd->x + cd->w && y >= cd->y && y < cd->y + cd->h)
- {
- proximity = TRUE;
- }
- }
- }
-
- if (proximity)
- set_mouse_cursor (ad, GDK_HAND2);
- else
- set_mouse_cursor (ad, GDK_LEFT_PTR);
-}
-
-static int display_click(GtkWidget *w, GdkEventButton *event, gpointer data)
-{
- AppData *ad = data;
- GList *list;
- gint x = (float)event->x;
- gint y = (float)event->y;
-
- if (event->button != 1)
- {
- return FALSE;
- }
-
- list = ad->click_list;
- while(list)
- {
- ClickData *cd = list->data;
-
- if (x >= cd->x && x < cd->x + cd->w && y >= cd->y && y < cd->y + cd->h)
- {
- if (cd->click_func) cd->click_func(ad, cd->data);
- }
-
- list = list->next;
- }
-
- return TRUE;
-}
-
-static void display_motion(GtkWidget *w, GdkEventMotion *event, gpointer data)
-{
- AppData *ad = data;
- GList *list;
- gint proximity = FALSE;
- gint x = (float)event->x;
- gint y = (float)event->y;
-
- list = ad->click_list;
- while(list)
- {
- ClickData *cd = list->data;
-
- if (x >= cd->x && x < cd->x + cd->w && y >= cd->y && y < cd->y + cd->h)
- {
- proximity = TRUE;
- }
-
- list = list->next;
- }
-
- if (proximity)
- set_mouse_cursor (ad, GDK_HAND2);
- else
- set_mouse_cursor (ad, GDK_LEFT_PTR);
-}
-
-void init_app_display(AppData *ad)
-{
- gint w, h;
-
- ad->scroll_delay = 20;
- ad->current_line = 0;
- ad->current_line_pos = 0;
- ad->scroll_count = 0;
- ad->scroll_pos = 0;
- ad->new_line = TRUE;
- ad->text_pos = 0;
-
- ad->text = NULL;
- ad->current_text = NULL;
- ad->click_list = NULL;
-
- ad->display_w = gnome_pixmap_new_from_xpm_d(back_xpm);
- ad->display = GNOME_PIXMAP(ad->display_w)->pixmap;
- ad->disp_buf_w = gnome_pixmap_new_from_xpm_d(back_xpm);
- ad->disp_buf = GNOME_PIXMAP(ad->disp_buf_w)->pixmap;
- ad->background_w = gnome_pixmap_new_from_xpm_d(back_xpm);
- ad->background = GNOME_PIXMAP(ad->background_w)->pixmap;
-
- gdk_window_get_size(ad->display, &w, &h);
-
- ad->width = w;
- ad->height = h;
-
- ad->frame = gtk_frame_new(NULL);
- gtk_frame_set_shadow_type(GTK_FRAME(ad->frame), GTK_SHADOW_IN);
- gtk_widget_show(ad->frame);
-
- ad->draw_area = gtk_drawing_area_new();
- gtk_drawing_area_size(GTK_DRAWING_AREA(ad->draw_area), w, h);
- gtk_widget_set_events (ad->draw_area, GDK_POINTER_MOTION_MASK | GDK_BUTTON_PRESS_MASK);
- gtk_signal_connect(GTK_OBJECT(ad->draw_area),"motion_notify_event",
- (GtkSignalFunc) display_motion, ad);
- gtk_signal_connect(GTK_OBJECT(ad->draw_area),"button_press_event",
- (GtkSignalFunc) display_click, ad);
- gtk_container_add(GTK_CONTAINER(ad->frame), ad->draw_area);
- gtk_widget_show(ad->draw_area);
-
- applet_widget_add(APPLET_WIDGET(ad->applet), ad->frame);
-
- gtk_widget_realize(ad->draw_area);
-
- ad->text_height = ad->draw_area->style->font->ascent +
- ad->draw_area->style->font->descent;
- ad->text_y_line = ad->draw_area->style->font->descent;
-
- ad->scroll_height = ad->text_height;
-
- redraw_display(ad);
-
- ad->display_timeout_id = gtk_timeout_add(UPDATE_DELAY, (GtkFunction)update_display_cb, ad);
-}
-
diff --git a/oldslashapp/http_get.c b/oldslashapp/http_get.c
deleted file mode 100644
index 18300e469..000000000
--- a/oldslashapp/http_get.c
+++ /dev/null
@@ -1,154 +0,0 @@
-#include "http_get.h"
-#include <string.h>
-#include <netdb.h>
-#include <errno.h>
-#include <sys/types.h>
-#include <sys/socket.h>
-#include <netinet/in.h>
-
-#define GET_BUFF_SIZE 256
-
-static int
-http_get_recv(int a_sd, void *a_buff, size_t a_buff_sz);
-
-static int
-http_get_send(int a_sd, void *a_buff, size_t a_buff_sz);
-
-int
-http_get_to_file(gchar *a_host, gint a_port, gchar *a_resource, FILE *a_file)
-{
- struct hostent *l_hostent = NULL;
- struct sockaddr_in l_addr;
- int l_return = 0;
- int l_socket = 0;
- char l_buff[GET_BUFF_SIZE];
- int l_bytes_read = 0;
- int l_reading_headers = 1;
- int l_first_cr_returned = 0;
- int l_second_cr_returned = 0;
-
- /* init the l_addr struct */
- memset(&l_addr, 0, sizeof(struct sockaddr_in));
- /* init the buffer */
- memset(l_buff, 0, GET_BUFF_SIZE);
- /* get the host info */
- l_hostent = gethostbyname(a_host);
- if (l_hostent == NULL)
- {
- l_return = -1;
- goto ec;
- }
- /* copy the address into into the structure. */
- memcpy(&l_addr.sin_addr.s_addr,
- l_hostent->h_addr_list[0],
- sizeof(unsigned long));
- /* set some stuff */
- l_addr.sin_family = AF_INET;
- l_addr.sin_port = htons(a_port);
- /* new socket */
- if ((l_socket = socket(AF_INET, SOCK_STREAM, 0)) < 0)
- {
- fprintf(stderr, "Failed to set up socket: %s\n", strerror(errno));
- l_return = -1;
- goto ec;
- }
- if (connect(l_socket, (struct sockaddr *)&l_addr, sizeof(struct sockaddr_in)) < 0)
- {
- fprintf(stderr, "Failed to connect to \"%s\": %s\n",
- a_host, strerror(errno));
- l_return = -1;
- goto ec;
- }
- if (http_get_send(l_socket, "GET ", strlen("GET ")) < strlen("GET "))
- {
- l_return = -1;
- goto ec;
- }
- if (http_get_send(l_socket, a_resource, strlen(a_resource)) < strlen(a_resource))
- {
- l_return = -1;
- goto ec;
- }
- if (http_get_send(l_socket, " HTTP/1.0\n\n", strlen(" HTTP/1.0\n\n")) < strlen(" HTTP/1.0\n\n"))
- {
- l_return = -1;
- goto ec;
- }
- while ((l_bytes_read = http_get_recv(l_socket, l_buff, 1)) > 0)
- {
- if (l_second_cr_returned && (l_buff[0] == '\n'))
- {
- break;
- }
- else if (l_first_cr_returned && (l_buff[0] == '\n'))
- {
- continue;
- }
- else if (l_first_cr_returned && (l_buff[0] == '\r'))
- {
- l_second_cr_returned = 1;
- }
- else if (l_buff[0] == '\r')
- {
- l_first_cr_returned = 1;
- }
- else
- {
- l_first_cr_returned = 0;
- l_second_cr_returned = 0;
- }
- }
- while ((l_bytes_read = http_get_recv(l_socket, l_buff, GET_BUFF_SIZE)) > 0)
- {
- fwrite(l_buff, l_bytes_read, 1, a_file);
- l_return += l_bytes_read;
- }
- fflush(a_file);
- close(l_socket);
- /* fprintf(stderr, "Resource recieved: %d bytes\n", l_return); */
- ec:
- return l_return;
-}
-
-static int
-http_get_send(int a_sd, void *a_buff, size_t a_buff_sz)
-{
- int l_total_ct;
- int l_write_ct;
-
- for (l_total_ct = 0; (l_total_ct < (int)a_buff_sz); l_total_ct += l_write_ct)
- {
- if ((l_write_ct = send(a_sd, ((char *) a_buff) + l_total_ct, a_buff_sz - l_total_ct, 0)) < 0)
- {
- goto ec;
- }
- }
-
- return l_total_ct;
-
- ec:
- return -1;
-}
-
-static int
-http_get_recv(int a_sd, void *a_buff, size_t a_buff_sz)
-{
- int l_total_ct;
- int l_read_ct;
-
- for (l_total_ct = 0; (l_total_ct < (int)a_buff_sz); l_total_ct += l_read_ct)
- {
- if ((l_read_ct = recv(a_sd, ((char *) a_buff) + l_total_ct, a_buff_sz - l_total_ct, 0)) < 0)
- {
- goto ec;
- }
- if (l_read_ct == 0)
- {
- break;
- }
- }
-
- return l_total_ct;
- ec:
- return -1;
-}
diff --git a/oldslashapp/http_get.h b/oldslashapp/http_get.h
deleted file mode 100644
index f7f750df8..000000000
--- a/oldslashapp/http_get.h
+++ /dev/null
@@ -1,11 +0,0 @@
-#ifndef HTTP_GET_H
-#define HTTP_GET_H
-
-#include <stdio.h>
-#include <unistd.h>
-#include <gtk/gtk.h>
-
-int
-http_get_to_file(gchar *a_host, gint a_port, gchar *a_resource, FILE *a_file);
-
-#endif
diff --git a/oldslashapp/noimage.xpm b/oldslashapp/noimage.xpm
deleted file mode 100644
index 972969723..000000000
--- a/oldslashapp/noimage.xpm
+++ /dev/null
@@ -1,27 +0,0 @@
-/* XPM */
-static char * noimage_xpm[] = {
-"20 20 4 1",
-" c None",
-". c #000000",
-"+ c #E24444",
-"@ c #FFFFFF",
-"....................",
-".++@@@@@@@@@@@@@@++.",
-".+++@@@@@@@@@@@@+++.",
-".@+++@@@@@@@@@@+++@.",
-".@@+++@@@@@@@@+++@@.",
-".@@@+++@@@@@@+++@@@.",
-".@@@@+++@@@@+++@@@@.",
-".@@@@@+++@@+++@@@@@.",
-".@@@@@@++++++@@@@@@.",
-".@@@@@@@++++@@@@@@@.",
-".@@@@@@@++++@@@@@@@.",
-".@@@@@@++++++@@@@@@.",
-".@@@@@+++@@+++@@@@@.",
-".@@@@+++@@@@+++@@@@.",
-".@@@+++@@@@@@+++@@@.",
-".@@+++@@@@@@@@+++@@.",
-".@+++@@@@@@@@@@+++@.",
-".+++@@@@@@@@@@@@+++.",
-".++@@@@@@@@@@@@@@++.",
-"...................."};
diff --git a/oldslashapp/properties.c b/oldslashapp/properties.c
deleted file mode 100644
index bea5b282c..000000000
--- a/oldslashapp/properties.c
+++ /dev/null
@@ -1,431 +0,0 @@
-/*###################################################################*/
-/*## ##*/
-/*###################################################################*/
-
-#include "slashapp.h"
-
-static void article_delay_cb(GtkObject *adj, gpointer data);
-static void browser_window_cb(GtkWidget *w, gpointer data);
-static void show_images_cb(GtkWidget *w, gpointer data);
-static void show_info_cb(GtkWidget *w, gpointer data);
-static void show_department_cb(GtkWidget *w, gpointer data);
-static void smooth_scroll_cb(GtkWidget *w, gpointer data);
-static void smooth_type_cb(GtkWidget *w, gpointer data);
-static void scroll_delay_cb(GtkObject *adj, gpointer data);
-static void scroll_speed_cb(GtkObject *adj, gpointer data);
-static void property_apply_cb(GtkWidget *widget, void *nodata, gpointer data);
-static gint property_destroy_cb(GtkWidget *widget, gpointer data);
-
-void property_load(gchar *path, AppData *ad)
-{
- gnome_config_push_prefix (path);
- ad->smooth_scroll = gnome_config_get_int("slashapp/smooth_scroll=1");
- ad->smooth_type = gnome_config_get_int("slashapp/smooth_type=1");
- ad->scroll_delay = gnome_config_get_int("slashapp/scroll_delay=10");
- ad->scroll_speed = gnome_config_get_int("slashapp/scroll_speed=3");
-
- ad->show_images = gnome_config_get_int("slashapp/show_images=1");
- ad->show_info = gnome_config_get_int("slashapp/show_info=1");
- ad->show_department = gnome_config_get_int("slashapp/show_department=0");
- ad->article_delay = gnome_config_get_int("slashapp/article_delay=50");
-
- ad->new_browser_window = gnome_config_get_int("slashapp/new_browser_window=1");
-
- gnome_config_pop_prefix ();
-}
-
-void property_save(gchar *path, AppData *ad)
-{
- gnome_config_push_prefix(path);
- gnome_config_set_int("slashapp/smooth_scroll", ad->smooth_scroll);
- gnome_config_set_int("slashapp/smooth_type", ad->smooth_type);
- gnome_config_set_int("slashapp/scroll_delay", ad->scroll_delay);
- gnome_config_set_int("slashapp/scroll_speed", ad->scroll_speed);
-
- gnome_config_set_int("slashapp/show_images", ad->show_images);
- gnome_config_set_int("slashapp/show_info", ad->show_info);
- gnome_config_set_int("slashapp/show_department", ad->show_department);
- gnome_config_set_int("slashapp/article_delay", ad->article_delay);
-
- gnome_config_set_int("slashapp/new_browser_window", ad->new_browser_window);
-
- gnome_config_sync();
- gnome_config_pop_prefix();
-}
-
-static void article_delay_cb(GtkObject *adj, gpointer data)
-{
- AppData *ad = data;
-
- if (GTK_IS_ADJUSTMENT(adj))
- ad->p_article_delay = (gint)GTK_ADJUSTMENT(adj)->value;
- else
- ad->p_article_delay = (gint)GTK_ADJUSTMENT(GTK_SPIN_BUTTON(adj)->adjustment)->value;
-
- gnome_property_box_changed(GNOME_PROPERTY_BOX(ad->propwindow));
-}
-
-static void browser_window_cb(GtkWidget *w, gpointer data)
-{
- AppData *ad = data;
- ad->p_new_browser_window = GTK_TOGGLE_BUTTON (w)->active;
- gnome_property_box_changed(GNOME_PROPERTY_BOX(ad->propwindow));
-}
-
-static void show_images_cb(GtkWidget *w, gpointer data)
-{
- AppData *ad = data;
- ad->p_show_images = GTK_TOGGLE_BUTTON (w)->active;
- gnome_property_box_changed(GNOME_PROPERTY_BOX(ad->propwindow));
-}
-
-static void show_info_cb(GtkWidget *w, gpointer data)
-{
- AppData *ad = data;
- ad->p_show_info = GTK_TOGGLE_BUTTON (w)->active;
- gnome_property_box_changed(GNOME_PROPERTY_BOX(ad->propwindow));
-}
-static void show_department_cb(GtkWidget *w, gpointer data)
-{
- AppData *ad = data;
- ad->p_show_department = GTK_TOGGLE_BUTTON (w)->active;
- gnome_property_box_changed(GNOME_PROPERTY_BOX(ad->propwindow));
-}
-
-static void smooth_scroll_cb(GtkWidget *w, gpointer data)
-{
- AppData *ad = data;
- ad->p_smooth_scroll = GTK_TOGGLE_BUTTON (w)->active;
- gnome_property_box_changed(GNOME_PROPERTY_BOX(ad->propwindow));
-}
-
-static void smooth_type_cb(GtkWidget *w, gpointer data)
-{
- AppData *ad = data;
- ad->p_smooth_type = GTK_TOGGLE_BUTTON (w)->active;
- gnome_property_box_changed(GNOME_PROPERTY_BOX(ad->propwindow));
-}
-
-static void scroll_delay_cb(GtkObject *adj, gpointer data)
-{
- AppData *ad = data;
-
- if (GTK_IS_ADJUSTMENT(adj))
- ad->p_scroll_delay = (gint)GTK_ADJUSTMENT(adj)->value;
- else
- ad->p_scroll_delay = (gint)GTK_ADJUSTMENT(GTK_SPIN_BUTTON(adj)->adjustment)->value;
-
- gnome_property_box_changed(GNOME_PROPERTY_BOX(ad->propwindow));
-}
-
-static void scroll_speed_cb(GtkObject *adj, gpointer data)
-{
- AppData *ad = data;
-
- if (GTK_IS_ADJUSTMENT(adj))
- ad->p_scroll_speed = (gint)GTK_ADJUSTMENT(adj)->value;
- else
- ad->p_scroll_speed = (gint)GTK_ADJUSTMENT(GTK_SPIN_BUTTON(adj)->adjustment)->value;
-
- gnome_property_box_changed(GNOME_PROPERTY_BOX(ad->propwindow));
-}
-
-static void property_apply_cb(GtkWidget *widget, void *nodata, gpointer data)
-{
- AppData *ad = data;
-
- ad->smooth_scroll = ad->p_smooth_scroll;
- ad->smooth_type = ad->p_smooth_type;
- ad->scroll_delay = ad->p_scroll_delay;
- ad->scroll_speed = ad->p_scroll_speed;
-
- ad->show_images = ad->p_show_images;
- ad->show_info = ad->p_show_info;
- ad->show_department = ad->p_show_department;
- ad->article_delay = ad->p_article_delay;
-
- ad->new_browser_window = ad->p_new_browser_window;
-
- applet_widget_sync_config(APPLET_WIDGET(ad->applet));
-}
-
-static gint property_destroy_cb(GtkWidget *widget, gpointer data)
-{
- AppData *ad = data;
- ad->propwindow = NULL;
- return FALSE;
-}
-
-void property_show(AppletWidget *applet, gpointer data)
-{
- AppData *ad = data;
- GtkWidget *frame;
- GtkWidget *vbox;
- GtkWidget *vbox1;
- GtkWidget *hbox;
- GtkWidget *label;
- GtkWidget *button;
- GtkObject *adj;
- GtkWidget *spin;
- GtkWidget *entry;
-
- if(ad->propwindow)
- {
- gdk_window_raise(ad->propwindow->window);
- return;
- }
-
- ad->p_smooth_scroll = ad->smooth_scroll;
- ad->p_smooth_type = ad->smooth_type;
- ad->p_scroll_delay = ad->scroll_delay;
- ad->p_scroll_speed = ad->scroll_speed;
-
- ad->p_show_images = ad->show_images;
- ad->p_show_info = ad->show_info;
- ad->p_show_department = ad->show_department;
- ad->p_article_delay = ad->article_delay;
-
- ad->p_new_browser_window = ad->new_browser_window;
-
- ad->propwindow = gnome_property_box_new();
- gtk_window_set_title(GTK_WINDOW(&GNOME_PROPERTY_BOX(ad->propwindow)->dialog.window),
- "Slashapp Settings");
-
- /* general tab */
-
- vbox = gtk_vbox_new(FALSE,0);
- gtk_widget_show(vbox);
-
- frame = gtk_frame_new(_("Articles"));
- gtk_container_set_border_width (GTK_CONTAINER (frame), 5);
- gtk_box_pack_start(GTK_BOX(vbox), frame, FALSE, FALSE, 0);
- gtk_widget_show(frame);
-
- vbox1 = gtk_vbox_new(FALSE, 1);
- gtk_container_add(GTK_CONTAINER(frame), vbox1);
- gtk_widget_show(vbox1);
-
- button = gtk_check_button_new_with_label (_("Show topic images"));
- gtk_box_pack_start(GTK_BOX(vbox1), button, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(button), ad->p_show_images);
- gtk_signal_connect (GTK_OBJECT(button),"clicked",(GtkSignalFunc) show_images_cb, ad);
- gtk_widget_show(button);
-
- button = gtk_check_button_new_with_label (_("Show department"));
- gtk_box_pack_start(GTK_BOX(vbox1), button, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(button), ad->p_show_department);
- gtk_signal_connect (GTK_OBJECT(button),"clicked",(GtkSignalFunc) show_department_cb, ad);
- gtk_widget_show(button);
-
- button = gtk_check_button_new_with_label (_("Show extra information (Time, Author, Comments)"));
- gtk_box_pack_start(GTK_BOX(vbox1), button, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(button), ad->p_show_info);
- gtk_signal_connect (GTK_OBJECT(button),"clicked",(GtkSignalFunc) show_info_cb, ad);
- gtk_widget_show(button);
-
- hbox = gtk_hbox_new(FALSE, 0);
- gtk_box_pack_start(GTK_BOX(vbox1), hbox, FALSE, FALSE, 0);
- gtk_widget_show(hbox);
-
- label = gtk_label_new(_("Delay between articles (10 = 1 sec):"));
- gtk_box_pack_start( GTK_BOX(hbox), label, FALSE, FALSE, 0);
- gtk_widget_show(label);
-
- adj = gtk_adjustment_new( ad->p_article_delay, 0.0, 3000.0 , 10, 10, 10 );
- spin = gtk_spin_button_new( GTK_ADJUSTMENT(adj), 1, 0 );
- gtk_box_pack_start( GTK_BOX(hbox), spin, FALSE, FALSE, 0);
- gtk_signal_connect( GTK_OBJECT(adj),"value_changed",
- GTK_SIGNAL_FUNC(article_delay_cb), ad);
- gtk_signal_connect( GTK_OBJECT(spin),"changed",
- GTK_SIGNAL_FUNC(article_delay_cb), ad);
- gtk_spin_button_set_update_policy(GTK_SPIN_BUTTON(spin), GTK_UPDATE_ALWAYS);
- gtk_widget_show(spin);
-
- label = gtk_label_new(_("(These settings do not take effect until a refresh)"));
- gtk_box_pack_start(GTK_BOX(vbox1), label, FALSE, FALSE, 0);
- gtk_widget_show(label);
-
-#if 0
- frame = gtk_frame_new(_("Browser"));
- gtk_container_set_border_width (GTK_CONTAINER (frame), 5);
- gtk_box_pack_start(GTK_BOX(vbox), frame, FALSE, FALSE, 0);
- gtk_widget_show(frame);
-
- vbox1 = gtk_vbox_new(FALSE, 1);
- gtk_container_add(GTK_CONTAINER(frame), vbox1);
- gtk_widget_show(vbox1);
-
- button = gtk_check_button_new_with_label (_("Open new window"));
- gtk_box_pack_start(GTK_BOX(vbox1), button, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(button), ad->p_new_browser_window);
- gtk_signal_connect (GTK_OBJECT(button),"clicked",(GtkSignalFunc) browser_window_cb, ad);
- gtk_widget_show(button);
-#endif
-
-/* -- not implemented yet --
-
- frame = gtk_frame_new(_("Ticker Information (unimplemented)"));
- gtk_container_set_border_width (GTK_CONTAINER (frame), 5);
- gtk_box_pack_start(GTK_BOX(vbox), frame, FALSE, FALSE, 0);
- gtk_widget_show(frame);
-
- vbox1 = gtk_vbox_new(FALSE, 1);
- gtk_container_add(GTK_CONTAINER(frame), vbox1);
- gtk_widget_show(vbox1);
-
- hbox = gtk_hbox_new(FALSE, 0);
- gtk_box_pack_start(GTK_BOX(vbox1), hbox, FALSE, FALSE, 0);
- gtk_widget_show(hbox);
-
- label = gtk_label_new(_("Url:"));
- gtk_box_pack_start( GTK_BOX(hbox), label, FALSE, FALSE, 0);
- gtk_widget_show(label);
-
- entry = gtk_entry_new_with_max_length(255);
- gtk_entry_set_text(GTK_ENTRY(entry), "slashdot.org");
- gtk_signal_connect_object(GTK_OBJECT(entry), "changed",
- GTK_SIGNAL_FUNC(gnome_property_box_changed),
- GTK_OBJECT(ad->propwindow));
- gtk_box_pack_start(GTK_BOX(hbox), entry ,TRUE, TRUE, 0);
- gtk_widget_set_sensitive(entry, FALSE);
- gtk_widget_show(entry);
-
- hbox = gtk_hbox_new(FALSE, 0);
- gtk_box_pack_start(GTK_BOX(vbox1), hbox, FALSE, FALSE, 0);
- gtk_widget_show(hbox);
-
- label = gtk_label_new(_("Article index file:"));
- gtk_box_pack_start( GTK_BOX(hbox), label, FALSE, FALSE, 0);
- gtk_widget_show(label);
-
- entry = gtk_entry_new_with_max_length(255);
- gtk_entry_set_text(GTK_ENTRY(entry), "/ultramode.txt");
- gtk_signal_connect_object(GTK_OBJECT(entry), "changed",
- GTK_SIGNAL_FUNC(gnome_property_box_changed),
- GTK_OBJECT(ad->propwindow));
- gtk_box_pack_start(GTK_BOX(hbox), entry ,TRUE, TRUE, 0);
- gtk_widget_set_sensitive(entry, FALSE);
- gtk_widget_show(entry);
-
- hbox = gtk_hbox_new(FALSE, 0);
- gtk_box_pack_start(GTK_BOX(vbox1), hbox, FALSE, FALSE, 0);
- gtk_widget_show(hbox);
-
- label = gtk_label_new(_("Image Server Url:"));
- gtk_box_pack_start( GTK_BOX(hbox), label, FALSE, FALSE, 0);
- gtk_widget_show(label);
-
- entry = gtk_entry_new_with_max_length(255);
- gtk_entry_set_text(GTK_ENTRY(entry), "wolfe.slashdot.org");
- gtk_signal_connect_object(GTK_OBJECT(entry), "changed",
- GTK_SIGNAL_FUNC(gnome_property_box_changed),
- GTK_OBJECT(ad->propwindow));
- gtk_box_pack_start(GTK_BOX(hbox), entry ,TRUE, TRUE, 0);
- gtk_widget_set_sensitive(entry, FALSE);
- gtk_widget_show(entry);
-
- hbox = gtk_hbox_new(FALSE, 0);
- gtk_box_pack_start(GTK_BOX(vbox1), hbox, FALSE, FALSE, 0);
- gtk_widget_show(hbox);
-
- label = gtk_label_new(_("Image path:"));
- gtk_box_pack_start( GTK_BOX(hbox), label, FALSE, FALSE, 0);
- gtk_widget_show(label);
-
- entry = gtk_entry_new_with_max_length(255);
- gtk_entry_set_text(GTK_ENTRY(entry), "/images/topics/topic");
- gtk_signal_connect_object(GTK_OBJECT(entry), "changed",
- GTK_SIGNAL_FUNC(gnome_property_box_changed),
- GTK_OBJECT(ad->propwindow));
- gtk_box_pack_start(GTK_BOX(hbox), entry, TRUE, TRUE, 0);
- gtk_widget_set_sensitive(entry, FALSE);
- gtk_widget_show(entry);
-
-
- --- */
-
- label = gtk_label_new(_("General"));
- gtk_widget_show(frame);
- gnome_property_box_append_page( GNOME_PROPERTY_BOX(ad->propwindow),vbox ,label);
-
- /* display tab */
-
- vbox = gtk_vbox_new(FALSE,0);
- gtk_widget_show(vbox);
-
- frame = gtk_frame_new(_("Scrolling"));
- gtk_container_set_border_width (GTK_CONTAINER (frame), 5);
- gtk_box_pack_start(GTK_BOX(vbox), frame, FALSE, FALSE, 0);
- gtk_widget_show(frame);
-
- vbox1 = gtk_vbox_new(FALSE, 1);
- gtk_container_add(GTK_CONTAINER(frame), vbox1);
- gtk_widget_show(vbox1);
-
- button = gtk_check_button_new_with_label (_("Smooth scroll"));
- gtk_box_pack_start(GTK_BOX(vbox1), button, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(button), ad->p_smooth_scroll);
- gtk_signal_connect (GTK_OBJECT(button),"clicked",(GtkSignalFunc) smooth_scroll_cb, ad);
- gtk_widget_show(button);
-
- /* does each line shows at once or if as it is typed by a human ? */
- button = gtk_check_button_new_with_label (_("Smooth type"));
- gtk_box_pack_start(GTK_BOX(vbox1), button, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(button), ad->p_smooth_type);
- gtk_signal_connect (GTK_OBJECT(button),"clicked",(GtkSignalFunc) smooth_type_cb, ad);
- gtk_widget_show(button);
-
- frame = gtk_frame_new(_("Speed"));
- gtk_container_set_border_width (GTK_CONTAINER (frame), 5);
- gtk_box_pack_start(GTK_BOX(vbox), frame, FALSE, FALSE, 0);
- gtk_widget_show(frame);
-
- vbox1 = gtk_vbox_new(FALSE, 1);
- gtk_container_add(GTK_CONTAINER(frame), vbox1);
- gtk_widget_show(vbox1);
-
- hbox = gtk_hbox_new(FALSE, 0);
- gtk_box_pack_start(GTK_BOX(vbox1), hbox, FALSE, FALSE, 0);
- gtk_widget_show(hbox);
-
- label = gtk_label_new(_("Delay when wrapping text:"));
- gtk_box_pack_start( GTK_BOX(hbox), label, FALSE, FALSE, 0);
- gtk_widget_show(label);
-
- adj = gtk_adjustment_new(ad->p_scroll_delay, 0.0, 50.0, 1, 1, 1 );
- spin = gtk_spin_button_new( GTK_ADJUSTMENT(adj), 1, 0 );
- gtk_box_pack_start( GTK_BOX(hbox), spin, FALSE, FALSE, 0);
- gtk_signal_connect( GTK_OBJECT(adj),"value_changed",
- GTK_SIGNAL_FUNC(scroll_delay_cb), ad);
- gtk_signal_connect( GTK_OBJECT(spin),"changed",
- GTK_SIGNAL_FUNC(scroll_delay_cb), ad);
- gtk_spin_button_set_update_policy(GTK_SPIN_BUTTON(spin), GTK_UPDATE_ALWAYS);
- gtk_widget_show(spin);
-
- hbox = gtk_hbox_new(FALSE, 0);
- gtk_box_pack_start(GTK_BOX(vbox1), hbox, FALSE, FALSE, 0);
- gtk_widget_show(hbox);
-
- label = gtk_label_new(_("Scroll speed between lines (Smooth scroll):"));
- gtk_box_pack_start( GTK_BOX(hbox), label, FALSE, FALSE, 0);
- gtk_widget_show(label);
-
- adj = gtk_adjustment_new( ad->p_scroll_speed, 1.0, (float)ad->scroll_height - 1, 1, 1, 1 );
- spin = gtk_spin_button_new( GTK_ADJUSTMENT(adj), 1, 0 );
- gtk_box_pack_start( GTK_BOX(hbox), spin, FALSE, FALSE, 0);
- gtk_signal_connect( GTK_OBJECT(adj),"value_changed",
- GTK_SIGNAL_FUNC(scroll_speed_cb), ad);
- gtk_signal_connect( GTK_OBJECT(spin),"changed",
- GTK_SIGNAL_FUNC(scroll_speed_cb), ad);
- gtk_spin_button_set_update_policy(GTK_SPIN_BUTTON(spin), GTK_UPDATE_ALWAYS);
- gtk_widget_show(spin);
-
- label = gtk_label_new(_("Display"));
- gtk_widget_show(frame);
- gnome_property_box_append_page( GNOME_PROPERTY_BOX(ad->propwindow),vbox ,label);
-
- gtk_signal_connect( GTK_OBJECT(ad->propwindow),"apply", GTK_SIGNAL_FUNC(property_apply_cb), ad);
- gtk_signal_connect( GTK_OBJECT(ad->propwindow),"destroy", GTK_SIGNAL_FUNC(property_destroy_cb), ad );
-
- gtk_widget_show_all(ad->propwindow);
-}
diff --git a/oldslashapp/slash_applet.desktop b/oldslashapp/slash_applet.desktop
deleted file mode 100644
index 274ba3243..000000000
--- a/oldslashapp/slash_applet.desktop
+++ /dev/null
@@ -1,46 +0,0 @@
-[Desktop Entry]
-Name=SlashApp
-Name[ca]=SlashApp
-Name[da]=SlashApp
-Name[de]=SlashApp
-Name[el]=SlashApp
-Name[es]=SlashApp
-Name[et]=SlashApp
-Name[fi]=SlashApp
-Name[fr]=SlashApp
-Name[gl]=SlashApp
-Name[hu]=SlashApp
-Name[it]=SlashApp
-Name[ja]=¥¹¥é¥Ã¥·¥å¥É¥Ã¥È
-Name[ko]=SlashApp
-Name[lt]=SlashApp
-Name[nl]=SlashApp
-Name[no]=SlashApp
-Name[pl]=SlashApp
-Name[pt]=SlashApp
-Name[wa]=SlashApp
-Comment=Show last news from slashdot.org
-Comment[ca]=Mostra les últimes notícies d'slashdot.org
-Comment[da]=Viser sidste nyt fra slashdot.org
-Comment[de]=Zeigt die letzten Neuigkeiten von slashdot.org
-Comment[el]=ÅìöÜíéóç ôùí ôåëåõôáßùí íÝùí áðü ôï slashdot.org
-Comment[es]=Últimas noticias de slashdot.org
-Comment[et]=Näitab viimaseid artikleid slashdot.org-st
-Comment[eu]=slashdot.org-en azken berriak
-Comment[fi]=Näyttää viimeisimmät uutiset slashdot.org:sta
-Comment[fr]=Dernières nouvelles de slashdot.org
-Comment[gl]=Amosa as últimas novas de slashdot.org
-Comment[hu]=A legfrissebb híreket mutatja a slashdot.org-ról
-Comment[it]=Visualizza le ultime notizie di slashdot.org
-Comment[ja]=slashdot.org¤ÎºÇ¿·¥Ë¥å¡¼¥¹¤òɽ¼¨
-Comment[ko]=slashdot.org¿¡¼­ ÃֽŠ´º½º¸¦ º¸¿©ÁÜ
-Comment[lt]=Rodo paskutines naujienas ið slashdot.org
-Comment[nl]=Het laatste nieuws van slashdot.org
-Comment[no]=Vis siste nyheter fra slashdot.org
-Comment[pl]=Wy¶wietla naj¶wie¿sze wiadomo¶ci ze slashdot.org
-Comment[pt]=Mostra as últimas notícias de slashdot.org
-Comment[wa]=Aplikete po vey les dierinnes noveles di slashdot.org èl scriftôr
-Exec=slash_applet --activate-goad-server=slash_applet
-Icon=
-Terminal=0
-Type=Application
diff --git a/oldslashapp/slash_applet.gnorba b/oldslashapp/slash_applet.gnorba
deleted file mode 100644
index 09b3b8d3a..000000000
--- a/oldslashapp/slash_applet.gnorba
+++ /dev/null
@@ -1,5 +0,0 @@
-[slash_applet]
-type=exe
-repo_id=IDL:GNOME/Applet:1.0
-description=slashdot headlines
-location_info=slash_applet
diff --git a/oldslashapp/slashapp.c b/oldslashapp/slashapp.c
deleted file mode 100644
index 1ec1cde66..000000000
--- a/oldslashapp/slashapp.c
+++ /dev/null
@@ -1,690 +0,0 @@
-/*###################################################################*/
-/*## ##*/
-/*###################################################################*/
-
-#include "slashapp.h"
-#include <ghttp.h>
-#include "slashsplash.xpm"
-#include <errno.h>
-#include <ctype.h>
-
-#if 0
-static void launch_url(AppData *ad, gchar *url);
-#endif
-static void click_headline_cb(AppData *ad, gpointer data);
-static int filesize(char *s);
-static gchar *check_for_dir(char *d);
-static void delete_if_empty(char *file);
-static GtkWidget *get_topic_image(gchar *topic, AppData *ad);
-static void make_lowercase(gchar *text);
-static void flush_newline_chars(gchar *text, gint max);
-static int get_current_headlines(gpointer data);
-static int startup_delay_cb(gpointer data);
-static void about_cb (AppletWidget *widget, gpointer data);
-static void destroy_applet(GtkWidget *widget, gpointer data);
-static gint applet_save_session(GtkWidget *widget, gchar *privcfgpath,
- gchar *globcfgpath, gpointer data);
-static AppData *create_new_app(GtkWidget *applet);
-static void applet_start_new_applet(const gchar *goad_id, gpointer data);
-
-static int
-http_get_to_file(gchar *a_host, gint a_port, gchar *a_resource, FILE *a_file)
-{
- int length = -1;
- ghttp_request *request = NULL;
- gchar s_port[8];
- gchar *uri = NULL;
- gchar *body;
- gchar *proxy = g_getenv("http_proxy");
-
- g_snprintf(s_port, 8, "%d", a_port);
- uri = g_strconcat("http://", a_host, ":", s_port, a_resource, NULL);
- /*fprintf(stderr,"Asking for %s\n", uri);*/
- request = ghttp_request_new();
- if (!request)
- goto ec;
- if (proxy && (ghttp_set_proxy(request,proxy) != 0))
- goto ec;
- if (ghttp_set_uri(request, uri) != 0)
- goto ec;
- ghttp_set_header(request, http_hdr_Connection, "close");
- if (ghttp_prepare(request) != 0)
- goto ec;
- if (ghttp_process(request) != ghttp_done)
- goto ec;
- length = ghttp_get_body_len(request);
- body = ghttp_get_body(request);
- if (body != NULL)
- fwrite(body, length, 1, a_file);
-
- ec:
- /*fprintf(stderr, "Resource received: %d bytes\n", length);*/
- if (request)
- ghttp_request_destroy(request);
- if (uri)
- g_free(uri);
- return length;
-}
-
-static void article_button_cb(GtkWidget *button, gpointer data)
-{
- AppData *ad = data;
- gchar *url;
- url = gtk_object_get_user_data(GTK_OBJECT(button));
- gnome_url_show(url);
-}
-
-static void destroy_article_window(GtkWidget *w, gpointer data)
-{
- AppData *ad = data;
- ad->article_window = NULL;
-}
-
-static void populate_article_window(AppData *ad)
-{
- GtkWidget *vbox;
- GtkWidget *hbox;
- GtkWidget *label;
- GtkWidget *button;
- GtkWidget *pixmap;
- GList *list;
- gint added = FALSE;
- if (!ad->article_window) return;
-
- vbox = gtk_object_get_user_data(GTK_OBJECT(ad->article_list));
-
- if (vbox) gtk_widget_destroy(vbox);
-
- vbox = gtk_vbox_new(FALSE, 5);
- gtk_scrolled_window_add_with_viewport(
- GTK_SCROLLED_WINDOW(ad->article_list), vbox);
- gtk_widget_show(vbox);
- gtk_object_set_user_data(GTK_OBJECT(ad->article_list), vbox);
-
- list = ad->text;
-
- while(list)
- {
- InfoData *id = list->data;
-
- if (id && id->data && id->show_count == 0)
- {
- if (added)
- {
- GtkWidget *sep = gtk_hseparator_new();
- gtk_box_pack_start(GTK_BOX(vbox), sep, FALSE, FALSE, 0);
- gtk_widget_show(sep);
- }
-
- hbox = gtk_hbox_new(FALSE, 5);
- gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
- gtk_widget_show(hbox);
-
- label = gtk_label_new(id->text);
- gtk_label_set_justify (GTK_LABEL(label), GTK_JUSTIFY_LEFT);
- gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 5);
- gtk_widget_show(label);
-
- button = gtk_button_new();
- gtk_object_set_user_data(GTK_OBJECT(button), id->data);
- gtk_signal_connect(GTK_OBJECT(button), "clicked",
- (GtkSignalFunc) article_button_cb, ad);
- gtk_box_pack_end(GTK_BOX(hbox), button, FALSE, FALSE, 5);
- gtk_widget_show(button);
-
- pixmap = gnome_stock_pixmap_widget_new(ad->article_window,
- GNOME_STOCK_PIXMAP_JUMP_TO);
- gtk_container_add(GTK_CONTAINER(button), pixmap);
- gtk_widget_show(pixmap);
-
- added = TRUE;
- }
-
- list = list->next;
- }
-
- if (!added)
- {
- hbox = gtk_hbox_new(FALSE, 5);
- gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
- gtk_widget_show(hbox);
-
- label = gtk_label_new(_("No articles"));
- gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0);
- gtk_widget_show(label);
- }
-
-}
-
-static void show_article_window(AppletWidget *widget, gpointer data)
-{
- AppData *ad = data;
-
- if (ad->article_window)
- {
- gdk_window_raise(ad->article_window->window);
- return;
- }
-
- ad->article_window = gnome_dialog_new(_("Slashapp article list"),
- GNOME_STOCK_BUTTON_CLOSE, NULL);
- gtk_widget_set_usize(ad->article_window, 400, 350);
-
- ad->article_list = gtk_scrolled_window_new(NULL, NULL);
- gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (ad->article_list),
- GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
- gtk_box_pack_start(GTK_BOX(GNOME_DIALOG(ad->article_window)->vbox),
- ad->article_list,TRUE,TRUE,0);
- gtk_widget_show(ad->article_list);
-
- gtk_object_set_user_data(GTK_OBJECT(ad->article_list), NULL);
-
- gnome_dialog_set_close (GNOME_DIALOG(ad->article_window), TRUE);
- gtk_signal_connect(GTK_OBJECT(ad->article_window), "destroy",
- (GtkSignalFunc) destroy_article_window, ad);
-
- populate_article_window(ad);
- gtk_widget_show(ad->article_window);
-}
-
-#if 0
-static void launch_url(AppData *ad, gchar *url)
-{
- gchar *command;
- char *argv[8];
- int status;
-
- if (ad->new_browser_window)
- command = g_strconcat("openURL(", url, ",new-window)", NULL);
- else
- command = g_strconcat("openURL(", url, ")", NULL);
-
- argv[0] = "netscape";
- argv[1] = "-remote";
- argv[2] = command;
- argv[3] = NULL;
-
- /* based on the web control applet */
- if(fork() == 0)
- {
- /* child */
- execvp (argv[0], argv);
- }
- else
- {
- wait(&status);
- if(WEXITSTATUS(status) != 0)
- {
- /* command didn't work */
- argv[0] = "netscape";
- argv[1] = url;
- argv[2] = NULL;
- if (gnome_execute_async (NULL, 2, argv) < 0)
- {
- printf("failed to start browser\n");
- }
- }
- }
-
- g_free(command);
-}
-#endif
-
-static void click_headline_cb(AppData *ad, gpointer data)
-{
- gchar *url = data;
- if (url)
- {
- gnome_url_show(url);
- }
-}
-
-static int filesize(char *s)
-{
- struct stat st;
-
- if ((!s)||(!*s)) return 0;
- if (stat(s,&st)<0) return 0;
- return (int)st.st_size;
-}
-
-static gchar *check_for_dir(char *d)
-{
- if (!g_file_exists(d))
- {
- g_print(_("creating user directory: %s\n"), d);
- if (mkdir( d, 0755 ) < 0)
- {
- g_print(_("unable to create user directory: %s\n"), d);
- g_free(d);
- d = NULL;
- }
- }
- return d;
-}
-
-static void delete_if_empty(char *file)
-{
- if (filesize(file) < 1) unlink(file);
-
- if (g_file_exists(file))
- {
- FILE *f = NULL;
- gchar buf[256];
- f = fopen (file, "r");
- if (!f) return;
- if (fgets(buf, sizeof(buf), f) == NULL)
- {
- fclose(f);
- unlink(file);
- return;
- }
- buf[255] = '\0';
- if (strstr(buf, "<HTML>") != NULL || strstr(buf, "<html>") != NULL)
- {
- fclose(f);
- unlink(file);
- return;
- }
- fclose(f);
- }
-}
-
-static GtkWidget *get_topic_image(gchar *topic, AppData *ad)
-{
- GtkWidget *icon = NULL;
- gchar *gif_file;
- gchar *jpg_file;
- gchar *icon_file;
- gchar *gif_filename;
- gchar *jpg_filename;
- gchar *image_topic;
- gchar *image_topic_end;
-
- /* sometimes, the topic has spaces (as in Sun Microsystems) */
- image_topic = g_strdup(topic);
- image_topic_end = strchr(image_topic,' ');
- if (image_topic_end)
- *image_topic_end = 0;
- /* treat some special cases */
- if (g_strcasecmp(image_topic,"technology")==0)
- image_topic[4] = 0;
-
- /* darn, must try both file types */
- gif_file = g_strconcat(image_topic, ".gif", NULL);
- jpg_file = g_strconcat(image_topic, ".jpg", NULL);
-
- gif_filename = g_strconcat(ad->slashapp_dir, "/", gif_file, NULL);
- jpg_filename = g_strconcat(ad->slashapp_dir, "/", jpg_file, NULL);
-
-
- if (!g_file_exists(gif_filename) && !g_file_exists(jpg_filename))
- {
- /* attempt download of images */
- FILE *f;
- gchar *gif_image;
- gchar *jpg_image;
-
- gif_image = g_strconcat("/images/topics/topic", gif_file, NULL);
- jpg_image = g_strconcat("/images/topics/topic", jpg_file, NULL);
-
-
- f = fopen(gif_filename, "w");
- if (f)
- {
- http_get_to_file("slashdot.wolfe.net", 80, gif_image, f);
- fclose(f);
- delete_if_empty(gif_filename);
- }
- if (!g_file_exists(gif_filename))
- {
- f = fopen(jpg_filename, "w");
- if (f)
- {
- http_get_to_file("slashdot.wolfe.net", 80, jpg_image, f);
- fclose(f);
- delete_if_empty(jpg_filename);
- }
- }
- g_free(gif_image);
- g_free(jpg_image);
- }
-
- if (g_file_exists(gif_filename))
- icon_file = gif_filename;
- else if (g_file_exists(jpg_filename))
- icon_file = jpg_filename;
- else
- {
- printf("could not load topic image: topic%s.[gif/jpg]\n", image_topic);
- icon_file = NULL;
- }
-
- if (icon_file)
- {
- icon = gnome_pixmap_new_from_file_at_size(icon_file, 20, 24);
- if (GNOME_PIXMAP(icon)->pixmap == NULL)
- {
- gtk_widget_destroy(icon);
- icon = NULL;
- }
- }
-
- g_free(image_topic);
- g_free(gif_file);
- g_free(jpg_file);
- g_free(gif_filename);
- g_free(jpg_filename);
- return icon;
-}
-
-static void make_lowercase(gchar *text)
-{
- gchar *p = text;
- while(p[0] != '\0')
- {
- if (isupper(p[0])) p[0] = tolower(p[0]);
- p++;
- }
-}
-
-static void flush_newline_chars(gchar *text, gint max)
-{
- gchar *p = text;
- gint c = 0;
- while (p[0] != '\0' && c <= max)
- {
- if (p[0] == '\n')
- p[0] = '\0';
- else
- {
- p++;
- c++;
- if (c >= max) p[0] = '\0';
- }
- }
-}
-
-static int get_current_headlines(gpointer data)
-{
- AppData *ad = data;
- InfoData *id;
- GtkWidget *icon;
- gchar buf[256];
- gchar headline[128];
- gchar url[128];
- gchar entrydate[64];
- gchar author[32];
- gchar department[128];
- gchar topic[32];
- gchar comments[12];
- FILE *slash_file = NULL;
- gchar *filename = g_strconcat(ad->slashapp_dir, "/slashnews", NULL);
- gint h = FALSE;
- gint delay = ad->article_delay / 10 * (1000 / UPDATE_DELAY);
-
-/* set_mouse_cursor (ad, GDK_WATCH);
-
- while(gtk_events_pending()) gtk_main_iteration(); */
-
- if ((slash_file = fopen(filename, "w")) == NULL)
- {
- fprintf(stderr, "Failed to open file \"%s\": %s\n",
- filename, strerror(errno));
- g_free(filename);
- set_mouse_cursor (ad, GDK_LEFT_PTR);
- return TRUE;
- }
-
- http_get_to_file("slashdot.org", 80, "/ultramode.txt", slash_file);
- fclose(slash_file);
-
- /* refresh the headlines in the display */
- if ((slash_file = fopen(filename, "r")) == NULL)
- {
- fprintf(stderr, "Failed to open file \"%s\": %s\n",
- filename, strerror(errno));
- g_free(filename);
- set_mouse_cursor (ad, GDK_LEFT_PTR);
- return TRUE;
- }
-
- /* clear the current headlines from display list */
- remove_all_lines(ad);
-
- /* add a generic header image */
- icon = gnome_pixmap_new_from_xpm_d(slashsplash_xpm);
- id = add_info_line_with_pixmap(ad, "", icon, 0, FALSE, 1, delay);
- set_info_click_signal(id, click_headline_cb, g_strdup("http://slashdot.org"), g_free);
- add_info_line(ad, "", NULL, 0, FALSE, 1, 0);
-
- while (fgets(buf, sizeof(buf), slash_file) != NULL)
- {
- if (strcmp(buf, "%%\n") == 0)
- {
- if (fgets(buf, sizeof(buf), slash_file) != NULL)
- {
- gchar *text;
- gchar *edate;
- h = TRUE;
- strncpy(headline, buf, 80);
- flush_newline_chars(headline, 80);
- fgets(buf, sizeof(buf), slash_file);
- strncpy(url, buf, 120);
- flush_newline_chars(url, 120);
- fgets(buf, sizeof(buf), slash_file);
- strncpy(entrydate, buf, 64);
- flush_newline_chars(entrydate, 23);
- if (strlen(entrydate) > 11)
- edate = entrydate + 11;
- else
- edate = entrydate;
- fgets(buf, sizeof(buf), slash_file);
- strncpy(author, buf, 10);
- flush_newline_chars(author, 8);
- fgets(buf, sizeof(buf), slash_file);
- strncpy(department, buf, 80);
- flush_newline_chars(department, 80);
- fgets(buf, sizeof(buf), slash_file);
- strncpy(topic, buf, 20);
- flush_newline_chars(topic, 16);
- make_lowercase(topic);
- fgets(buf, sizeof(buf), slash_file);
- strncpy(comments, buf, 8);
- flush_newline_chars(comments, 7);
-
- icon = NULL;
- if (ad->show_images) icon = get_topic_image(topic, ad);
-
- if (ad->show_department)
- text = g_strconcat(headline, "\nDpt: ", department , NULL);
- else
- text = g_strdup(headline);
-
- if (ad->show_info)
- {
- gchar *temp = g_strconcat(text, "\n[ ", edate, " by " , author, " ] (", comments,")", NULL);
- g_free(text);
- text = temp;
- }
-
- /* add the headline */
- if (icon)
- id = add_info_line_with_pixmap(ad, text, icon, 0, FALSE, FALSE, delay);
- else
- id = add_info_line(ad, text, NULL, 0, FALSE, FALSE, delay);
- set_info_click_signal(id, click_headline_cb, g_strdup(url), g_free);
-
- /* a space separator, could include a graphic divider too */
- add_info_line(ad, "", NULL, 0, FALSE, 0, 0);
- g_free(text);
- }
- }
- }
-
- fclose(slash_file);
-
- set_mouse_cursor (ad, GDK_LEFT_PTR);
-
- if (!h)
- {
- add_info_line(ad, " \n ", NULL, 0, FALSE, 1, 0);
- add_info_line(ad, _("No articles found"), NULL, 0, TRUE, 1, 30);
- }
-
- populate_article_window(ad);
-
- g_free(filename);
- return TRUE;
-}
-
-static int startup_delay_cb(gpointer data)
-{
- AppData *ad = data;
- get_current_headlines(ad);
- ad->startup_timeout_id = 0;
- return FALSE; /* return false to stop this timeout callback, needed only once */
-}
-
-static void refresh_cb(AppletWidget *widget, gpointer data)
-{
- AppData *ad = data;
- if (ad->startup_timeout_id > 0) return;
- ad->startup_timeout_id = gtk_timeout_add(5000, startup_delay_cb, ad);
-}
-
-
-static void about_cb (AppletWidget *widget, gpointer data)
-{
- GtkWidget *about;
- const gchar *authors[5];
- gchar version[32];
-
- sprintf(version,_("%d.%d.%d"),APPLET_VERSION_MAJ,
- APPLET_VERSION_MIN, APPLET_VERSION_REV);
-
- authors[0] = _("Justin Maurer <justin@openprojects.net>");
- authors[3] = _("Craig Small <csmall@eye-net.com.au>");
- authors[1] = _("John Ellis <johne@bellatlantic.net> - Display engine");
- /* languages that can display "e with acute" can use "Frédéric" */
- authors[2] = _("Frederic Devernay <devernay@istar.fr>");
- authors[4] = NULL;
-
- about = gnome_about_new ( _("SlashApp"), version,
- _("(C) 1998"),
- authors,
- _("A ticker to display Slashdot headlines\n"),
- NULL);
- gtk_widget_show (about);
-}
-
-
-static void destroy_applet(GtkWidget *widget, gpointer data)
-{
- AppData *ad = data;
-
- gtk_timeout_remove(ad->display_timeout_id);
- gtk_timeout_remove(ad->headline_timeout_id);
- if (ad->startup_timeout_id > 0) gtk_timeout_remove(ad->startup_timeout_id);
-
- free_all_info_lines(ad);
- gtk_widget_destroy(ad->display_w);
- gtk_widget_destroy(ad->disp_buf_w);
- gtk_widget_destroy(ad->background_w);
- g_free(ad);
-}
-
-static gint applet_save_session(GtkWidget *widget, gchar *privcfgpath,
- gchar *globcfgpath, gpointer data)
-{
- AppData *ad = data;
- property_save(privcfgpath, ad);
- return FALSE;
-}
-
-static AppData *create_new_app(GtkWidget *applet)
-{
- AppData *ad;
- ad = g_new0(AppData, 1);
-
- ad->applet = applet;
- ad->article_window = NULL;
- ad->slashapp_dir = check_for_dir(gnome_util_home_file("slashapp"));
- if (!ad->slashapp_dir) exit;
-
- init_app_display(ad);
- gtk_signal_connect(GTK_OBJECT(ad->applet), "destroy",
- GTK_SIGNAL_FUNC(destroy_applet), ad);
-
- property_load(APPLET_WIDGET(applet)->privcfgpath, ad);
-
- add_info_line(ad, "SlashApp\n", NULL, 0, TRUE, 1, 0);
- add_info_line(ad, _("Loading headlines........"), NULL, 0, FALSE, 1, 20);
-
-/* applet signals */
- gtk_signal_connect(GTK_OBJECT(applet),"save_session",
- GTK_SIGNAL_FUNC(applet_save_session),
- ad);
- applet_widget_register_stock_callback(APPLET_WIDGET(applet),
- "properties",
- GNOME_STOCK_MENU_PROP,
- _("Properties..."),
- property_show,
- ad);
- applet_widget_register_stock_callback(APPLET_WIDGET(applet),
- "about",
- GNOME_STOCK_MENU_ABOUT,
- _("About..."),
- about_cb, NULL);
- applet_widget_register_stock_callback(APPLET_WIDGET(applet),
- "articles",
- GNOME_STOCK_MENU_BOOK_OPEN,
- _("Show article listing"),
- show_article_window, ad);
- applet_widget_register_stock_callback(APPLET_WIDGET(applet),
- "refresh",
- GNOME_STOCK_MENU_REFRESH,
- _("Refresh articles"),
- refresh_cb, ad);
-
- ad->headline_timeout_id = gtk_timeout_add(1800000, get_current_headlines, ad);
-
- gtk_widget_show(ad->applet);
-
- /* this is so the app is displayed first before calling the download command */
- ad->startup_timeout_id = gtk_timeout_add(5000, startup_delay_cb, ad);
-
- return ad;
-}
-
-static void applet_start_new_applet(const gchar *goad_id, gpointer data)
-{
- GtkWidget *applet;
-
- applet = applet_widget_new(goad_id);
- if (!applet)
- g_error("Can't create applet!\n");
-
- create_new_app(applet);
-}
-
-int main (int argc, char *argv[])
-{
- GtkWidget *applet;
-
- /* Initialize the i18n stuff */
- bindtextdomain (PACKAGE, GNOMELOCALEDIR);
- textdomain (PACKAGE);
-
- applet_widget_init("slash_applet", VERSION, argc, argv, NULL,
- 0, NULL);
-
- applet = applet_widget_new("slash_applet");
- if (!applet)
- g_error("Can't create applet!\n");
-
- create_new_app(applet);
-
- applet_widget_gtk_main();
- return 0;
-}
diff --git a/oldslashapp/slashapp.h b/oldslashapp/slashapp.h
deleted file mode 100644
index aedea42f8..000000000
--- a/oldslashapp/slashapp.h
+++ /dev/null
@@ -1,153 +0,0 @@
-/*###################################################################*/
-/*## Slash applet for GNOME ##*/
-/*###################################################################*/
-
-#include <sys/types.h>
-#include <config.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <unistd.h>
-#include <sys/stat.h>
-#include <sys/wait.h>
-
-#include <gnome.h>
-#include <applet-widget.h>
-
-#define APPLET_VERSION_MAJ 0
-#define APPLET_VERSION_MIN 3
-#define APPLET_VERSION_REV 2
-
-#define UPDATE_DELAY 70
-
-typedef struct _AppData AppData;
-struct _AppData
-{
- GtkWidget *applet;
- GtkWidget *frame;
- GtkWidget *draw_area;
- gint height;
- gint width;
-
- gint scroll_delay;
- gint scroll_speed;
- gint scroll_height;
- gint smooth_scroll;
- gint smooth_type;
-
- GtkWidget *display_w;
- GtkWidget *disp_buf_w;
- GtkWidget *background_w;
- GdkPixmap *display;
- GdkPixmap *disp_buf;
- GdkPixmap *background;
-
- GdkColor text_color;
-
- GList *text; /* GList of InfoData structs */
- GList *current_text; /* GList of current_text */
- gint text_lines;
-
- gint current_line;
- gint current_line_pos;
-
- gint scroll_count;
- gint scroll_pos;
- gint new_line;
- gint x_pos;
- gint text_pos;
-
- gint text_height;
- gint text_y_line;
-
- gint display_timeout_id;
-
- GList *click_list; /* GList of clickable target on display */
-
- /* properties stuff */
-
- GtkWidget *propwindow;
-
- gint p_smooth_scroll;
- gint p_smooth_type;
- gint p_scroll_delay;
- gint p_scroll_speed;
-
- /* per app stuff (when writing an actual applet based on this, put new vars here) */
-
- gint headline_timeout_id;
- gint startup_timeout_id;
-
- gchar *slashapp_dir;
-
- gint show_images;
- gint show_info;
- gint show_department;
- gint p_show_images;
- gint p_show_info;
- gint p_show_department;
-
- gint new_browser_window;
- gint p_new_browser_window;
-
- gint article_delay;
- gint p_article_delay;
-
- GtkWidget *article_window;
- GtkWidget *article_list;
-};
-
-typedef struct _InfoData InfoData;
-struct _InfoData
-{
- gchar *text; /* any length, but be reasonable */
- gint length;
- gchar *icon_path; /* location of icon */
- GtkWidget *icon; /* maximum 24 x 24 please (or be reasonable)*/
- gint icon_w;
- gint icon_h;
- gint offset; /* offset of text from left, set to line text up even with no icon */
- gint center; /* Center text, only has effect if text fits on one line */
- gint shown;
- gint show_count; /* when 0 show forever, other wise times to show (1 or +) */
- gint end_delay; /* time to delay after displaying last character of text
- this number is calculated from tenths of a second */
-
- /* click callback stuff */
-
- void (*click_func)(AppData *ad, gpointer data);
- gpointer data;
- void (*free_func)(gpointer data);
-};
-
-typedef struct _ClickData ClickData;
-struct _ClickData
-{
- InfoData *line_id;
- gint x;
- gint y;
- gint w;
- gint h;
- void (*click_func)(AppData *ad, gpointer data);
- gpointer data;
-
-};
-
- /* display.c */
-void free_all_info_lines(AppData *ad);
-InfoData *add_info_line(AppData *ad, gchar *text, gchar *icon_path, gint offset, gint center,
- gint show_count, gint delay);
-InfoData *add_info_line_with_pixmap(AppData *ad, gchar *text, GtkWidget *icon, gint offset, gint center,
- gint show_count, gint delay);
-void remove_info_line(AppData *ad, InfoData *id);
-void remove_all_lines(AppData *ad);
-void set_info_click_signal(InfoData *id, void (*click_func)(AppData *ad, gpointer data),
- gpointer data, void (*free_func)(gpointer data));
-void set_mouse_cursor (AppData *ad, gint icon);
-void init_app_display(AppData *ad);
-
- /* properties.c */
-void property_load(gchar *path, AppData *ad);
-void property_save(gchar *path, AppData *ad);
-void property_show(AppletWidget *applet, gpointer data);
-
diff --git a/oldslashapp/slashsplash.gif b/oldslashapp/slashsplash.gif
deleted file mode 100644
index 5412bd513..000000000
--- a/oldslashapp/slashsplash.gif
+++ /dev/null
Binary files differ
diff --git a/oldslashapp/slashsplash.xpm b/oldslashapp/slashsplash.xpm
deleted file mode 100644
index de9c34175..000000000
--- a/oldslashapp/slashsplash.xpm
+++ /dev/null
@@ -1,75 +0,0 @@
-/* XPM */
-static char * slashsplash_xpm[] = {
-"240 40 32 1",
-" c None",
-". c #FFFFFF",
-"+ c #073A3C",
-"@ c #0A5A54",
-"# c #0C6261",
-"$ c #026664",
-"% c #064A44",
-"& c #2E7A7C",
-"* c #628E8C",
-"= c #6AA6A4",
-"- c #428A8C",
-"; c #1A1E1C",
-"> c #CAD2D4",
-", c #FEFEFC",
-"' c #E2E6E4",
-") c #8DB3B2",
-"! c #AACAC4",
-"~ c #929A9C",
-"{ c #072A2C",
-"] c #868A84",
-"^ c #020404",
-"/ c #B2B6BC",
-"( c #262A2C",
-"_ c #5A5E5C",
-": c #A6AAA4",
-"< c #2E6A64",
-"[ c #464A4C",
-"} c #363A3C",
-"| c #4A7674",
-"1 c #646664",
-"2 c #325A54",
-"3 c #2E4A4C",
-"...................+@#$$$$$$$$$$$$$$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$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$",
-",,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,.........................................................................................",
-",,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,.........................................................................................",
-",,,,,,,,,$-,,$>,,,,,,,,,,,,,,,,,'@1,,,,,,,,,,$/,,$/,,,,,,,,,,><:,,,,,,,,,,,-$%-),-',,,,,'&%'$[,,'*,$2,,,,,,,,-),,,,,,,,,,,,,,=*,!/,,,,,,,,,,,,,,,,,,,,,.........................................................................................",
-",,,,,,,,,$@,,$>,,,,,,,,,,,,,,,,,'%~,,,,,,,,,,$*',$~,,,,,,,,,,>%],,,,,,,,,,'${]@@,$:,,,,,>&['@],,'@,$+,,,,,,,,$+,,,,,,,,,,,,,,-@>)3,,,,,,,,,,,,,,,,,,,,,.........................................................................................",
-",,,,,,,,,@+*,$>&$$>&/,$>*|$@<,,,-@1-<$),$$|,,@@&,$~-$$)'$$_)@$%]&2<,,,,,,,'$<''/!$3*$,-]-$%=@[,,*@_$@<&,-$$)!$%),>$&$<$'>$$<,$@1&%:!<$'!$$]$@*',,,,,,,,.........................................................................................",
-",,,,,,,,,@3&>$)%{>@)1)%1@*&|]/,,'%'$~'$'@~>,,@]-:$]$+>@>@~>$1!%1@*1>,,,,,,,>_@$=,@~*$,-1>&1'@',,'%,$+'$>:+*%,${,,>+1$}*2,1*$>-@>){>$}!$!$_>@)_],,,,,,,,.........................................................................................",
-",,,,,,,,,@3'@$)%323>@$(@%>)~$),,'%'$,,$>@,,,,@:,$$]@+22~@',@/>%]~|$/,,,,,,)>,,=$'@~*$,-1>&1'@',,'%,$+,$:@+1%,${,,>+]$[*2&@[$>-@>){>$323!$:,*|$*,,,,,,,,.........................................................................................",
-",,,,,,,,,@3,)$>&$=@>-@!$[>&-$},,'%'&--{'@,,,,@:,!$~-$=@)@',=&$%]$*$}!),,,,'@&=${'$)>&=$1>&1'@',,'@,$+,$/$<$@,$%,,>+]$[*2&@-$>-@!)%,)<-%!$:,$=$;=!,,,,,,.........................................................................................",
-",,,,,,,,,@[,,%>:2<;'=+,&],)@%1,,'+'>%2(,+,,,,<:,,%~>2<^!%','%+{]=@%]>{,,,,,2%<;(,|2,/@21'-1'%',,,@1&{,</-%+%>*%/,'+]*[)[>@2+]>@|,%/'%<;>&:,<@{()_,,,,,,.........................................................................................",
-",,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,.........................................................................................",
-",,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,.........................................................................................",
-",,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,.........................................................................................",
-",,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,........................................................................................."};