view plugins/toc_commands.c @ 338:9d258a0aa560

[gaim-migrate @ 348] Whoa, all kinds of things happened here. The applet looks better. The preferences dialog changes based on your compile-time options (oscar, gnome). Whispering works again. libfaim got updated; it can almost do RVOUS stuff, and hopefully soon can make requests too. The applet doesn't need to have its sounds go through GNOME, although it still can. There is code to facilitate SOCKS5 support (all that needs to be done is to actually write the code to communicate with the proxy server). committer: Tailor Script <tailor@pidgin.im>
author Eric Warmenhoven <eric@warmenhoven.org>
date Tue, 06 Jun 2000 09:55:30 +0000
parents 8d8faeab01f6
children ae7c762775cd
line wrap: on
line source

#define GAIM_PLUGINS
#include "gaim.h"

#include <gtk/gtk.h>

void enter_callback(GtkWidget *widget, GtkWidget *entry) {
	gchar *entry_text;
	entry_text = gtk_entry_get_text(GTK_ENTRY(entry));
	sflap_send(entry_text, strlen(entry_text), TYPE_DATA);
}

GtkWidget *window;
void gaim_plugin_init(void *h) {
	GtkWidget *entry;

	window = gtk_window_new(GTK_WINDOW_DIALOG);
	gtk_window_set_title(GTK_WINDOW(window), "Gaim - SFLAP interface");

	entry = gtk_entry_new();
	gtk_signal_connect(GTK_OBJECT(entry), "activate",
			   (GtkSignalFunc)enter_callback,
			   entry);
	gtk_container_add(GTK_CONTAINER(window), entry);
	gtk_widget_show(entry);

	gtk_widget_show(window);
}

void gaim_plugin_remove() {
	gtk_widget_destroy(window);
}

char *name() {
	return "TOC Interface";
}

char *description() {
	return "Allows you to talk directly to the TOC server, bypassing gaim.";
}