|
|
2010-06-18
, 19:17
|
|
Posts: 26 |
Thanked: 2 times |
Joined on Apr 2010
|
#41
|
|
|
2010-06-20
, 02:43
|
|
|
Posts: 57 |
Thanked: 10 times |
Joined on Jun 2010
|
#42
|
|
|
2010-06-20
, 11:38
|
|
Posts: 19 |
Thanked: 2 times |
Joined on Jun 2010
|
#43
|
problem solved:
just go to ~/.purple and delete "prefs.xml".
a new prefs.xml will be created on next pidgin startup.
it seems that old/false preferences are responsible for this error.
-------------------
popups on maemo? i don't know...
the only thing i can imagine:
using dbus to show the messages
(the theme-colored banners which appear when something important happens - i hope you know what i mean xD)
|
|
2010-06-20
, 15:16
|
|
|
Posts: 355 |
Thanked: 205 times |
Joined on Jun 2010
@ Germany
|
#44
|
|
|
2010-06-22
, 16:23
|
|
|
Posts: 1,090 |
Thanked: 476 times |
Joined on Jan 2010
@ Ingolstadt, Germany
|
#45
|
b. ...or can i program my phone through xserver to make it do this?
start on started hildon-desktop
script
run-standalone.sh /usr/bin/pidgin
end script
c. ... ARGGG!!!
| The Following User Says Thank You to b666m For This Useful Post: | ||
|
|
2010-06-22
, 16:33
|
|
|
Posts: 1,090 |
Thanked: 476 times |
Joined on Jan 2010
@ Ingolstadt, Germany
|
#46
|
I mean, when you get an SMS at the top left appears a little bar/popup or something like that. Is that possible with pidgin? Cause I get it with integrated msn, but I really prefered pidgin.
Thanks!
dbus-send-notification "foo bar boo bah bang"
| The Following User Says Thank You to b666m For This Useful Post: | ||
|
|
2010-06-23
, 16:47
|
|
|
Posts: 1,090 |
Thanked: 476 times |
Joined on Jan 2010
@ Ingolstadt, Germany
|
#47
|
#include <glib.h>
#include <glib-object.h>
#include <dbus/dbus.h>
#include <dbus/dbus-glib.h>
#include <hildon/hildon-notification.h>
#include "marshal.h" /* The file generated from marshal.list via tool glib-genmarshal */
/* pidgin dbus station name */
#define DBUS_SERVICE_PURPLE "im.pidgin.purple.PurpleService"
#define DBUS_PATH_PURPLE "/im/pidgin/purple/PurpleObject"
#define DBUS_INTERFACE_PURPLE "im.pidgin.purple.PurpleInterface"
/* global dbus instance */
DBusGConnection *bus;
DBusGProxy *purple_proxy;
/* Main event loop */
GMainLoop *loop = NULL;
/* Signal callback handling routing */
void received_im_msg_cb (DBusGProxy *purple_proxy, int account_id,
const char *sender, const char *message,
int conv_id, unsigned int flags,
gpointer user_data)
{
HildonNotification *n = NULL;
n = hildon_notification_new( sender, message, "pidgin", "network" );
/* maybe someone can find an dbus call for bringing the current conversation
window to foreground when being clicked - using the "com.nokia.SOMETHING" interface */
/* an example for using the pidgin interface - not tried yet ^^ */
/* hildon_notification_add_dbus_action( n, "default", "pidgin",
DBUS_SERVICE_PURPLE,
DBUS_PATH_PURPLE,
DBUS_INTERFACE_PURPLE,
"$METHOD", // see http://developer.pidgin.im/wiki/DbusHowto#CallingPidginmethods for methods?!
G_TYPE_NONE, NULL,
-1 ); */
notify_notification_show( NOTIFY_NOTIFICATION( n ), NULL );
g_timeout_add_seconds( 2, close_notification, n );
}
/*
* The main process, loop waiting for any signals
*/
int main (int argc, char **argv)
{
GError *error = NULL;
g_type_init ();
/* Get the bus */
bus = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
if (bus == NULL) {
g_printerr("Failed to open connection to bus: %s", error->message);
g_error_free(error);
return -1;
}
/* Create a proxy object for the bus driver */
purple_proxy = dbus_g_proxy_new_for_name (bus,
DBUS_SERVICE_PURPLE,
DBUS_PATH_PURPLE,
DBUS_INTERFACE_PURPLE);
if (!purple_proxy) {
g_printerr("Couldn't connect to the Purple Service: %s", error->message);
g_error_free(error);
return -1;
}
/* Create the main loop instance */
loop = g_main_loop_new (NULL, FALSE);
/* Register dbus signal marshaller */
dbus_g_object_register_marshaller(marshal_VOID__INT_STRING_STRING_INT_UINT,
G_TYPE_NONE, G_TYPE_INT, G_TYPE_STRING,
G_TYPE_STRING, G_TYPE_INT, G_TYPE_UINT,
G_TYPE_INVALID);
/* Add the signal to the proxy */
dbus_g_proxy_add_signal(purple_proxy, "ReceivedImMsg",
G_TYPE_INT, G_TYPE_STRING, G_TYPE_STRING,
G_TYPE_INT, G_TYPE_UINT, G_TYPE_INVALID);
/* Connect the signal handler to the proxy */
dbus_g_proxy_connect_signal(purple_proxy, "ReceivedImMsg",
G_CALLBACK(received_im_msg_cb), bus, NULL);
/* Main loop */
g_main_loop_run (loop);
return 0;
}
#!/bin/sh DAEMON=/usr/bin/pidginnotifyd DSMETOOL=/usr/sbin/dsmetool DSMETOOL_PARAMETERS="-t" $DSMETOOL $DSMETOOL_PARAMETERS $DAEMON
|
|
2010-06-23
, 22:13
|
|
|
Posts: 1,090 |
Thanked: 476 times |
Joined on Jan 2010
@ Ingolstadt, Germany
|
#48
|
*yay*void received_im_msg_cb (DBusGProxy *purple_proxy, int account_id,
const char *sender, const char *message,
int conv_id, unsigned int flags,
gpointer user_data)
{
g_print("Account %d receives msg \"%s\" from %s\n",
account_id, message, sender);
}
b666m@xb666mx:~/pidgin$ ./pidginnotifyd Account 1100 receives msg "-" from xxx767xxx


| The Following User Says Thank You to b666m For This Useful Post: | ||
|
|
2010-06-24
, 00:02
|
|
|
Posts: 1,090 |
Thanked: 476 times |
Joined on Jan 2010
@ Ingolstadt, Germany
|
#50
|
#include <libpurple/account.h>
const char *purple_account_get_alias(const PurpleAccount *account);
/* Signal callback handling routing */
void received_im_msg_cb (DBusGProxy *purple_proxy, int account_id,
const char *sender, const char *message,
int conv_id, unsigned int flags,
gpointer user_data)
{
/* need to inlcude "account.h" for following functions */
const PurpleAccount *account;
const char *alias;
const char *icon_path;
const char *protocol;
// PurpleAccount *purple_accounts_find_any(const char *name, const char *protocol);
// PurpleAccount *purple_accounts_find_connected(const char *name, const char *protocol);
account = purple_accounts_find(sender, NULL);
/* get the alias */
alias = purple_account_get_alias(account);
/* get the icon path */
icon_path = purple_account_get_buddy_icon_path(account);
/* get the protocol name */
protocol = purple_account_get_protocol_name(account);
g_print("Account %d receives msg \"%s\" from %s\n",
account_id, message, sender);
g_print("Alias %s, Path %s, Protocol %s", alias, icon_path, protocol);
}
sudo gcc -MMD -Wall -ggdb -O `pkg-config --cflags dbus-1 glib-2.0 dbus-glib-1` `pkg-config --libs dbus-1 glib-2.0 dbus-glib-1` marshal.c pidginnotifyd.c -o pidginnotifyd
/tmp/ccVoXEPd.o: In function `received_im_msg_cb': /home/b666m/pidgin/pidginnotifyd.c:37: undefined reference to `purple_accounts_find' /home/b666m/pidgin/pidginnotifyd.c:40: undefined reference to `purple_account_get_alias' /home/b666m/pidgin/pidginnotifyd.c:42: undefined reference to `purple_account_get_buddy_icon_path' /home/b666m/pidgin/pidginnotifyd.c:44: undefined reference to `purple_account_get_protocol_name' collect2: ld returned 1 exit status
sudo gcc -MMD -Wall -ggdb -O `pkg-config --cflags dbus-1 glib-2.0 dbus-glib-1 pidgin` `pkg-config --libs dbus-1 glib-2.0 dbus-glib-1 pidgin` marshal.c pidginnotifyd.c -o pidginnotifyd