Moved the "About" dialog to the main application
This commit is contained in:
parent
e1c5d565dc
commit
88075c4bff
@ -38,6 +38,7 @@ typedef struct _PhonePluginHelper
|
|||||||
int (*config_set)(Phone * phone, char const * section,
|
int (*config_set)(Phone * phone, char const * section,
|
||||||
char const * variable, char const * value);
|
char const * variable, char const * value);
|
||||||
int (*error)(Phone * phone, char const * message, int ret);
|
int (*error)(Phone * phone, char const * message, int ret);
|
||||||
|
void (*about_dialog)(Phone * phone);
|
||||||
int (*event)(Phone * phone, PhoneEvent * event);
|
int (*event)(Phone * phone, PhoneEvent * event);
|
||||||
void (*message)(Phone * phone, PhoneMessage message, ...);
|
void (*message)(Phone * phone, PhoneMessage message, ...);
|
||||||
int (*request)(Phone * phone, ModemRequest * request);
|
int (*request)(Phone * phone, ModemRequest * request);
|
||||||
|
156
po/fr.po
156
po/fr.po
@ -8,7 +8,7 @@ msgid ""
|
|||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: Phone 0.0.0\n"
|
"Project-Id-Version: Phone 0.0.0\n"
|
||||||
"Report-Msgid-Bugs-To: \n"
|
"Report-Msgid-Bugs-To: \n"
|
||||||
"POT-Creation-Date: 2011-08-28 18:15+0200\n"
|
"POT-Creation-Date: 2011-08-28 19:22+0200\n"
|
||||||
"PO-Revision-Date: 2010-04-24 02:07+0200\n"
|
"PO-Revision-Date: 2010-04-24 02:07+0200\n"
|
||||||
"Last-Translator: Pierre Pronchery <khorben@defora.org>\n"
|
"Last-Translator: Pierre Pronchery <khorben@defora.org>\n"
|
||||||
"Language-Team: DeforaOS development (French) <devel-fr@lists.defora.org>\n"
|
"Language-Team: DeforaOS development (French) <devel-fr@lists.defora.org>\n"
|
||||||
@ -27,305 +27,309 @@ msgstr ""
|
|||||||
" -m\tNom du greffon modem à charger\n"
|
" -m\tNom du greffon modem à charger\n"
|
||||||
" -r\tDélai entre deux tentatives d'accès au modem (ms)\n"
|
" -r\tDélai entre deux tentatives d'accès au modem (ms)\n"
|
||||||
|
|
||||||
#: ../src/phone.c:337
|
#: ../src/phone.c:355
|
||||||
msgid "All"
|
msgid "All"
|
||||||
msgstr "Tous"
|
msgstr "Tous"
|
||||||
|
|
||||||
#: ../src/phone.c:338
|
#: ../src/phone.c:356
|
||||||
msgid "Inbox"
|
msgid "Inbox"
|
||||||
msgstr "Reçus"
|
msgstr "Reçus"
|
||||||
|
|
||||||
#: ../src/phone.c:339
|
#: ../src/phone.c:357
|
||||||
msgid "Sent"
|
msgid "Sent"
|
||||||
msgstr "Envoyés"
|
msgstr "Envoyés"
|
||||||
|
|
||||||
#: ../src/phone.c:340
|
#: ../src/phone.c:358
|
||||||
msgid "Drafts"
|
msgid "Drafts"
|
||||||
msgstr "Brouillons"
|
msgstr "Brouillons"
|
||||||
|
|
||||||
#: ../src/phone.c:341
|
#: ../src/phone.c:359
|
||||||
msgid "Trash"
|
msgid "Trash"
|
||||||
msgstr "Corbeille"
|
msgstr "Corbeille"
|
||||||
|
|
||||||
#: ../src/phone.c:509 ../src/phone.c:2522
|
#: ../src/phone.c:529 ../src/phone.c:2573
|
||||||
msgid "System preferences"
|
msgid "System preferences"
|
||||||
msgstr "Préférences système"
|
msgstr "Préférences système"
|
||||||
|
|
||||||
#: ../src/phone.c:520 ../src/phone.c:1951
|
#: ../src/phone.c:540 ../src/phone.c:2002
|
||||||
msgid "Plug-ins"
|
msgid "Plug-ins"
|
||||||
msgstr "Greffons"
|
msgstr "Greffons"
|
||||||
|
|
||||||
#: ../src/phone.c:685
|
#: ../src/phone.c:705
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Checking %s..."
|
msgid "Checking %s..."
|
||||||
msgstr "Vérification %s..."
|
msgstr "Vérification %s..."
|
||||||
|
|
||||||
#: ../src/phone.c:748
|
#: ../src/phone.c:768
|
||||||
msgid "Delete this contact?"
|
msgid "Delete this contact?"
|
||||||
msgstr "Supprimer ce contact?"
|
msgstr "Supprimer ce contact?"
|
||||||
|
|
||||||
#: ../src/phone.c:1058 ../src/phone.c:1224
|
#: ../src/phone.c:1078 ../src/phone.c:1244
|
||||||
msgid "Delete this message?"
|
msgid "Delete this message?"
|
||||||
msgstr "Supprimer ce message?"
|
msgstr "Supprimer ce message?"
|
||||||
|
|
||||||
#: ../src/phone.c:1064 ../src/phone.c:1229
|
#: ../src/phone.c:1084 ../src/phone.c:1249
|
||||||
msgid "Deleting message..."
|
msgid "Deleting message..."
|
||||||
msgstr "Suppression du message..."
|
msgstr "Suppression du message..."
|
||||||
|
|
||||||
#: ../src/phone.c:1335
|
#: ../src/phone.c:1332
|
||||||
|
msgid "translator-credits"
|
||||||
|
msgstr "Pierre Pronchery <khorben@defora.org>"
|
||||||
|
|
||||||
|
#: ../src/phone.c:1386
|
||||||
msgid "Unknown contact"
|
msgid "Unknown contact"
|
||||||
msgstr "Contact inconnu"
|
msgstr "Contact inconnu"
|
||||||
|
|
||||||
#: ../src/phone.c:1342
|
#: ../src/phone.c:1393
|
||||||
msgid "Unknown number"
|
msgid "Unknown number"
|
||||||
msgstr "Numéro inconnu"
|
msgstr "Numéro inconnu"
|
||||||
|
|
||||||
#: ../src/phone.c:1354
|
#: ../src/phone.c:1405
|
||||||
msgid "In conversation"
|
msgid "In conversation"
|
||||||
msgstr "En conversation"
|
msgstr "En conversation"
|
||||||
|
|
||||||
#: ../src/phone.c:1365
|
#: ../src/phone.c:1416
|
||||||
msgid "Incoming call"
|
msgid "Incoming call"
|
||||||
msgstr "Appel entrant"
|
msgstr "Appel entrant"
|
||||||
|
|
||||||
#: ../src/phone.c:1375
|
#: ../src/phone.c:1426
|
||||||
msgid "Outgoing call"
|
msgid "Outgoing call"
|
||||||
msgstr "Appel sortant"
|
msgstr "Appel sortant"
|
||||||
|
|
||||||
#: ../src/phone.c:1386
|
#: ../src/phone.c:1437
|
||||||
msgid "Call finished"
|
msgid "Call finished"
|
||||||
msgstr "Appel terminé"
|
msgstr "Appel terminé"
|
||||||
|
|
||||||
#: ../src/phone.c:1418
|
#: ../src/phone.c:1469
|
||||||
msgid "_Answer"
|
msgid "_Answer"
|
||||||
msgstr "_Répondre"
|
msgstr "_Répondre"
|
||||||
|
|
||||||
#: ../src/phone.c:1423
|
#: ../src/phone.c:1474
|
||||||
msgid "_Hangup"
|
msgid "_Hangup"
|
||||||
msgstr "Ra_ccrocher"
|
msgstr "Ra_ccrocher"
|
||||||
|
|
||||||
#: ../src/phone.c:1428
|
#: ../src/phone.c:1479
|
||||||
msgid "_Reject"
|
msgid "_Reject"
|
||||||
msgstr "Re_jeter"
|
msgstr "Re_jeter"
|
||||||
|
|
||||||
#: ../src/phone.c:1448
|
#: ../src/phone.c:1499
|
||||||
msgid "Loudspeaker"
|
msgid "Loudspeaker"
|
||||||
msgstr "Haut-parleur"
|
msgstr "Haut-parleur"
|
||||||
|
|
||||||
#: ../src/phone.c:1456
|
#: ../src/phone.c:1507
|
||||||
msgid "Mute microphone"
|
msgid "Mute microphone"
|
||||||
msgstr "Couper le microphone"
|
msgstr "Couper le microphone"
|
||||||
|
|
||||||
#: ../src/phone.c:1498
|
#: ../src/phone.c:1549
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Enter %s"
|
msgid "Enter %s"
|
||||||
msgstr "Entrer %s"
|
msgstr "Entrer %s"
|
||||||
|
|
||||||
#: ../src/phone.c:1541
|
#: ../src/phone.c:1592
|
||||||
msgid "Enter"
|
msgid "Enter"
|
||||||
msgstr "Entrer"
|
msgstr "Entrer"
|
||||||
|
|
||||||
#: ../src/phone.c:1543
|
#: ../src/phone.c:1594
|
||||||
msgid "Skip"
|
msgid "Skip"
|
||||||
msgstr "Ignorer"
|
msgstr "Ignorer"
|
||||||
|
|
||||||
#: ../src/phone.c:1571
|
#: ../src/phone.c:1622
|
||||||
msgid "Contacts"
|
msgid "Contacts"
|
||||||
msgstr "Contacts"
|
msgstr "Contacts"
|
||||||
|
|
||||||
#: ../src/phone.c:1577 ../src/phone.c:1696 ../src/phone.c:1732
|
#: ../src/phone.c:1628 ../src/phone.c:1747 ../src/phone.c:1783
|
||||||
#: ../src/phone.c:1847 ../src/phone.c:2203
|
#: ../src/phone.c:1898 ../src/phone.c:2254
|
||||||
msgid "Call"
|
msgid "Call"
|
||||||
msgstr "Appeler"
|
msgstr "Appeler"
|
||||||
|
|
||||||
#: ../src/phone.c:1583
|
#: ../src/phone.c:1634
|
||||||
msgid "Write"
|
msgid "Write"
|
||||||
msgstr "Écrire"
|
msgstr "Écrire"
|
||||||
|
|
||||||
#: ../src/phone.c:1625 ../src/phone.c:1982 ../src/phone.c:2314
|
#: ../src/phone.c:1676 ../src/phone.c:2033 ../src/phone.c:2365
|
||||||
msgid "Name"
|
msgid "Name"
|
||||||
msgstr "Nom"
|
msgstr "Nom"
|
||||||
|
|
||||||
#: ../src/phone.c:1671
|
#: ../src/phone.c:1722
|
||||||
msgid "Dialer"
|
msgid "Dialer"
|
||||||
msgstr "Composer"
|
msgstr "Composer"
|
||||||
|
|
||||||
#: ../src/phone.c:1698
|
#: ../src/phone.c:1749
|
||||||
msgid "Hang up"
|
msgid "Hang up"
|
||||||
msgstr "Raccrocher"
|
msgstr "Raccrocher"
|
||||||
|
|
||||||
#: ../src/phone.c:1726
|
#: ../src/phone.c:1777
|
||||||
msgid "Phone logs"
|
msgid "Phone logs"
|
||||||
msgstr "Journal d'appels"
|
msgstr "Journal d'appels"
|
||||||
|
|
||||||
#: ../src/phone.c:1738
|
#: ../src/phone.c:1789
|
||||||
msgid "Message"
|
msgid "Message"
|
||||||
msgstr "Message"
|
msgstr "Message"
|
||||||
|
|
||||||
#: ../src/phone.c:1769
|
#: ../src/phone.c:1820
|
||||||
msgid "Direction"
|
msgid "Direction"
|
||||||
msgstr "Direction"
|
msgstr "Direction"
|
||||||
|
|
||||||
#: ../src/phone.c:1774 ../src/phone.c:1893
|
#: ../src/phone.c:1825 ../src/phone.c:1944
|
||||||
msgid "To/From"
|
msgid "To/From"
|
||||||
msgstr "Vers/De"
|
msgstr "Vers/De"
|
||||||
|
|
||||||
#: ../src/phone.c:1780 ../src/phone.c:1901
|
#: ../src/phone.c:1831 ../src/phone.c:1952
|
||||||
msgid "Date"
|
msgid "Date"
|
||||||
msgstr "Date"
|
msgstr "Date"
|
||||||
|
|
||||||
#: ../src/phone.c:1841
|
#: ../src/phone.c:1892
|
||||||
msgid "Messages"
|
msgid "Messages"
|
||||||
msgstr "Messages"
|
msgstr "Messages"
|
||||||
|
|
||||||
#: ../src/phone.c:1852
|
#: ../src/phone.c:1903
|
||||||
msgid "New message"
|
msgid "New message"
|
||||||
msgstr "Nouveau message"
|
msgstr "Nouveau message"
|
||||||
|
|
||||||
#: ../src/phone.c:1858 ../src/phone.c:2209
|
#: ../src/phone.c:1909 ../src/phone.c:2260
|
||||||
msgid "Reply"
|
msgid "Reply"
|
||||||
msgstr "Répondre"
|
msgstr "Répondre"
|
||||||
|
|
||||||
#: ../src/phone.c:1970
|
#: ../src/phone.c:2021
|
||||||
msgid "Enabled"
|
msgid "Enabled"
|
||||||
msgstr "Activé"
|
msgstr "Activé"
|
||||||
|
|
||||||
#: ../src/phone.c:2197
|
#: ../src/phone.c:2248
|
||||||
msgid "Read message"
|
msgid "Read message"
|
||||||
msgstr "Lire le message"
|
msgstr "Lire le message"
|
||||||
|
|
||||||
#: ../src/phone.c:2215
|
#: ../src/phone.c:2266
|
||||||
msgid "Forward"
|
msgid "Forward"
|
||||||
msgstr "Transmettre"
|
msgstr "Transmettre"
|
||||||
|
|
||||||
#: ../src/phone.c:2289
|
#: ../src/phone.c:2340
|
||||||
msgid "Phone settings"
|
msgid "Phone settings"
|
||||||
msgstr "Paramètres du téléphone"
|
msgstr "Paramètres du téléphone"
|
||||||
|
|
||||||
#: ../src/phone.c:2366
|
#: ../src/phone.c:2417
|
||||||
msgid "missed calls"
|
msgid "missed calls"
|
||||||
msgstr "appels manqués"
|
msgstr "appels manqués"
|
||||||
|
|
||||||
#: ../src/phone.c:2366
|
#: ../src/phone.c:2417
|
||||||
msgid "missed call"
|
msgid "missed call"
|
||||||
msgstr "appel manqué"
|
msgstr "appel manqué"
|
||||||
|
|
||||||
#: ../src/phone.c:2375
|
#: ../src/phone.c:2426
|
||||||
msgid "new messages"
|
msgid "new messages"
|
||||||
msgstr "nouveaux messages"
|
msgstr "nouveaux messages"
|
||||||
|
|
||||||
#: ../src/phone.c:2376
|
#: ../src/phone.c:2427
|
||||||
msgid "new message"
|
msgid "new message"
|
||||||
msgstr "nouveau message"
|
msgstr "nouveau message"
|
||||||
|
|
||||||
#: ../src/phone.c:2394 ../src/phone.c:3299 ../src/phone.c:3303
|
#: ../src/phone.c:2445 ../src/phone.c:3358 ../src/phone.c:3362
|
||||||
msgid "Information"
|
msgid "Information"
|
||||||
msgstr "Information"
|
msgstr "Information"
|
||||||
|
|
||||||
#: ../src/phone.c:2404
|
#: ../src/phone.c:2455
|
||||||
msgid "Status"
|
msgid "Status"
|
||||||
msgstr "État"
|
msgstr "État"
|
||||||
|
|
||||||
#: ../src/phone.c:2428
|
#: ../src/phone.c:2479
|
||||||
msgid "_View"
|
msgid "_View"
|
||||||
msgstr "_Vue"
|
msgstr "_Vue"
|
||||||
|
|
||||||
#: ../src/phone.c:2447
|
#: ../src/phone.c:2498
|
||||||
msgid "_Read"
|
msgid "_Read"
|
||||||
msgstr "_Lire"
|
msgstr "_Lire"
|
||||||
|
|
||||||
#: ../src/phone.c:2548
|
#: ../src/phone.c:2599
|
||||||
msgid "Open file..."
|
msgid "Open file..."
|
||||||
msgstr "Ouvrir fichier..."
|
msgstr "Ouvrir fichier..."
|
||||||
|
|
||||||
#: ../src/phone.c:2734
|
#: ../src/phone.c:2786
|
||||||
msgid "Write message"
|
msgid "Write message"
|
||||||
msgstr "Écrire un message"
|
msgstr "Écrire un message"
|
||||||
|
|
||||||
#: ../src/phone.c:2740
|
#: ../src/phone.c:2792
|
||||||
msgid "Send"
|
msgid "Send"
|
||||||
msgstr "Envoyer"
|
msgstr "Envoyer"
|
||||||
|
|
||||||
#: ../src/phone.c:2746
|
#: ../src/phone.c:2798
|
||||||
msgid "Attach"
|
msgid "Attach"
|
||||||
msgstr "Joindre"
|
msgstr "Joindre"
|
||||||
|
|
||||||
#: ../src/phone.c:2862
|
#: ../src/phone.c:2914
|
||||||
msgid "Attach file..."
|
msgid "Attach file..."
|
||||||
msgstr "Joindre un fichier..."
|
msgstr "Joindre un fichier..."
|
||||||
|
|
||||||
#: ../src/phone.c:2933
|
#: ../src/phone.c:2985
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%d message%s, %d/%d characters"
|
msgid "%d message%s, %d/%d characters"
|
||||||
msgstr "%d message%s, %d/%d caractères"
|
msgstr "%d message%s, %d/%d caractères"
|
||||||
|
|
||||||
#: ../src/phone.c:2934
|
#: ../src/phone.c:2986
|
||||||
msgid "s"
|
msgid "s"
|
||||||
msgstr "s"
|
msgstr "s"
|
||||||
|
|
||||||
#: ../src/phone.c:2998
|
#: ../src/phone.c:3050
|
||||||
msgid "Sending message..."
|
msgid "Sending message..."
|
||||||
msgstr "Envoi du message..."
|
msgstr "Envoi du message..."
|
||||||
|
|
||||||
#: ../src/phone.c:3027
|
#: ../src/phone.c:3086
|
||||||
msgid "Outgoing"
|
msgid "Outgoing"
|
||||||
msgstr "Sortant"
|
msgstr "Sortant"
|
||||||
|
|
||||||
#: ../src/phone.c:3213
|
#: ../src/phone.c:3272
|
||||||
msgid "Operation in progress..."
|
msgid "Operation in progress..."
|
||||||
msgstr "Opération en cours..."
|
msgstr "Opération en cours..."
|
||||||
|
|
||||||
#: ../src/phone.c:3251 ../src/phone.c:3255
|
#: ../src/phone.c:3310 ../src/phone.c:3314
|
||||||
msgid "Question"
|
msgid "Question"
|
||||||
msgstr "Question"
|
msgstr "Question"
|
||||||
|
|
||||||
#: ../src/phone.c:3275 ../src/phone.c:3279
|
#: ../src/phone.c:3334 ../src/phone.c:3338
|
||||||
msgid "Error"
|
msgid "Error"
|
||||||
msgstr "Erreur"
|
msgstr "Erreur"
|
||||||
|
|
||||||
#: ../src/phone.c:3505
|
#: ../src/phone.c:3564
|
||||||
msgid "Name: "
|
msgid "Name: "
|
||||||
msgstr "Nom: "
|
msgstr "Nom: "
|
||||||
|
|
||||||
#: ../src/phone.c:3514
|
#: ../src/phone.c:3573
|
||||||
msgid "Number: "
|
msgid "Number: "
|
||||||
msgstr "Numéro: "
|
msgstr "Numéro: "
|
||||||
|
|
||||||
#: ../src/phone.c:3530
|
#: ../src/phone.c:3589
|
||||||
msgid "New contact"
|
msgid "New contact"
|
||||||
msgstr "Nouveau contact"
|
msgstr "Nouveau contact"
|
||||||
|
|
||||||
#: ../src/phone.c:3532
|
#: ../src/phone.c:3591
|
||||||
msgid "Edit contact: "
|
msgid "Edit contact: "
|
||||||
msgstr "Modifier contact: "
|
msgstr "Modifier contact: "
|
||||||
|
|
||||||
#: ../src/phone.c:3559
|
#: ../src/phone.c:3618
|
||||||
msgid "The name cannot be empty"
|
msgid "The name cannot be empty"
|
||||||
msgstr "Le nom ne peut être vide"
|
msgstr "Le nom ne peut être vide"
|
||||||
|
|
||||||
#: ../src/phone.c:3564
|
#: ../src/phone.c:3623
|
||||||
msgid "The number cannot be empty"
|
msgid "The number cannot be empty"
|
||||||
msgstr "Le numéro ne peut être vide"
|
msgstr "Le numéro ne peut être vide"
|
||||||
|
|
||||||
#: ../src/phone.c:3700
|
#: ../src/phone.c:3759
|
||||||
msgid "Message sent"
|
msgid "Message sent"
|
||||||
msgstr "Message envoyé"
|
msgstr "Message envoyé"
|
||||||
|
|
||||||
#: ../src/phone.c:3731
|
#: ../src/phone.c:3790
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Wrong %s"
|
msgid "Wrong %s"
|
||||||
msgstr "Mauvais %s"
|
msgstr "Mauvais %s"
|
||||||
|
|
||||||
#: ../src/phone.c:3738
|
#: ../src/phone.c:3797
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "%s is valid"
|
msgid "%s is valid"
|
||||||
msgstr "%s valide"
|
msgstr "%s valide"
|
||||||
|
|
||||||
#: ../src/phone.c:3803
|
#: ../src/phone.c:3862
|
||||||
msgid "Raw data (not shown)"
|
msgid "Raw data (not shown)"
|
||||||
msgstr "Données brutes (non affichées)"
|
msgstr "Données brutes (non affichées)"
|
||||||
|
|
||||||
#: ../src/phone.c:3836
|
#: ../src/phone.c:3895
|
||||||
msgid "Message deleted"
|
msgid "Message deleted"
|
||||||
msgstr "Message effacé"
|
msgstr "Message effacé"
|
||||||
|
|
||||||
|
10
src/Makefile
10
src/Makefile
@ -6,7 +6,7 @@ BINDIR = $(PREFIX)/bin
|
|||||||
CC = cc
|
CC = cc
|
||||||
CPPFLAGSF= -I ../include
|
CPPFLAGSF= -I ../include
|
||||||
CPPFLAGS=
|
CPPFLAGS=
|
||||||
CFLAGSF = -W `pkg-config --cflags libSystem gtk+-2.0`
|
CFLAGSF = -W
|
||||||
CFLAGS = -Wall -g -O2 -pedantic
|
CFLAGS = -Wall -g -O2 -pedantic
|
||||||
LDFLAGSF= `pkg-config --libs libSystem gtk+-2.0`
|
LDFLAGSF= `pkg-config --libs libSystem gtk+-2.0`
|
||||||
LDFLAGS = -L $(PREFIX)/lib -Wl,-rpath,$(PREFIX)/lib
|
LDFLAGS = -L $(PREFIX)/lib -Wl,-rpath,$(PREFIX)/lib
|
||||||
@ -22,15 +22,15 @@ subdirs:
|
|||||||
@for i in $(SUBDIRS); do (cd $$i && $(MAKE)) || exit; done
|
@for i in $(SUBDIRS); do (cd $$i && $(MAKE)) || exit; done
|
||||||
|
|
||||||
phone_OBJS = callbacks.o main.o modem.o phone.o
|
phone_OBJS = callbacks.o main.o modem.o phone.o
|
||||||
phone_CFLAGS = $(CPPFLAGSF) $(CPPFLAGS) $(CFLAGSF) $(CFLAGS)
|
phone_CFLAGS = $(CPPFLAGSF) $(CPPFLAGS) $(CFLAGSF) $(CFLAGS) `pkg-config --cflags libDesktop`
|
||||||
phone_LDFLAGS = $(LDFLAGSF) $(LDFLAGS)
|
phone_LDFLAGS = $(LDFLAGSF) $(LDFLAGS) `pkg-config --libs libDesktop`
|
||||||
|
|
||||||
phone: $(phone_OBJS)
|
phone: $(phone_OBJS)
|
||||||
$(CC) -o phone $(phone_OBJS) $(phone_LDFLAGS)
|
$(CC) -o phone $(phone_OBJS) $(phone_LDFLAGS)
|
||||||
|
|
||||||
phonectl_OBJS = phonectl.o
|
phonectl_OBJS = phonectl.o
|
||||||
phonectl_CFLAGS = $(CPPFLAGSF) $(CPPFLAGS) $(CFLAGSF) $(CFLAGS)
|
phonectl_CFLAGS = $(CPPFLAGSF) $(CPPFLAGS) $(CFLAGSF) $(CFLAGS) `pkg-config --cflags gtk+-2.0`
|
||||||
phonectl_LDFLAGS = $(LDFLAGSF) $(LDFLAGS)
|
phonectl_LDFLAGS = $(LDFLAGSF) $(LDFLAGS) `pkg-config --libs gtk+-2.0`
|
||||||
|
|
||||||
phonectl: $(phonectl_OBJS)
|
phonectl: $(phonectl_OBJS)
|
||||||
$(CC) -o phonectl $(phonectl_OBJS) $(phonectl_LDFLAGS)
|
$(CC) -o phonectl $(phonectl_OBJS) $(phonectl_LDFLAGS)
|
||||||
|
87
src/phone.c
87
src/phone.c
@ -1,17 +1,18 @@
|
|||||||
/* $Id$ */
|
/* $Id$ */
|
||||||
/* Copyright (c) 2011 Pierre Pronchery <khorben@defora.org> */
|
/* Copyright (c) 2011 Pierre Pronchery <khorben@defora.org> */
|
||||||
/* This file is part of DeforaOS Desktop Phone */
|
/* This file is part of DeforaOS Desktop Phone */
|
||||||
/* This program is free software: you can redistribute it and/or modify
|
static char const _license[] =
|
||||||
* it under the terms of the GNU General Public License as published by
|
"This program is free software: you can redistribute it and/or modify\n"
|
||||||
* the Free Software Foundation, version 3 of the License.
|
"it under the terms of the GNU General Public License as published by\n"
|
||||||
*
|
"the Free Software Foundation, version 3 of the License.\n"
|
||||||
* This program is distributed in the hope that it will be useful,
|
"\n"
|
||||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
"This program is distributed in the hope that it will be useful,\n"
|
||||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
|
||||||
* GNU General Public License for more details.
|
"MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n"
|
||||||
*
|
"GNU General Public License for more details.\n"
|
||||||
* You should have received a copy of the GNU General Public License
|
"\n"
|
||||||
* along with this program. If not, see <http://www.gnu.org/licenses/>. */
|
"You should have received a copy of the GNU General Public License\n"
|
||||||
|
"along with this program. If not, see <http://www.gnu.org/licenses/>.";
|
||||||
/* FIXME:
|
/* FIXME:
|
||||||
* - keep track of missed calls */
|
* - keep track of missed calls */
|
||||||
|
|
||||||
@ -28,6 +29,7 @@
|
|||||||
#include <libintl.h>
|
#include <libintl.h>
|
||||||
#include <gtk/gtk.h>
|
#include <gtk/gtk.h>
|
||||||
#include <System.h>
|
#include <System.h>
|
||||||
|
#include <Desktop.h>
|
||||||
#include "Phone.h"
|
#include "Phone.h"
|
||||||
#include "modem.h"
|
#include "modem.h"
|
||||||
#include "callbacks.h"
|
#include "callbacks.h"
|
||||||
@ -160,6 +162,9 @@ struct _Phone
|
|||||||
/* widgets */
|
/* widgets */
|
||||||
PangoFontDescription * bold;
|
PangoFontDescription * bold;
|
||||||
|
|
||||||
|
/* about */
|
||||||
|
GtkWidget * ab_window;
|
||||||
|
|
||||||
/* call */
|
/* call */
|
||||||
GtkWidget * ca_window;
|
GtkWidget * ca_window;
|
||||||
GtkWidget * ca_name;
|
GtkWidget * ca_name;
|
||||||
@ -255,7 +260,20 @@ struct _Phone
|
|||||||
#define PHONE_CONFIG_FILE ".phone"
|
#define PHONE_CONFIG_FILE ".phone"
|
||||||
|
|
||||||
|
|
||||||
|
/* variables */
|
||||||
|
static char const * _authors[] =
|
||||||
|
{
|
||||||
|
"Pierre Pronchery <khorben@defora.org>",
|
||||||
|
NULL
|
||||||
|
};
|
||||||
|
|
||||||
|
static char _copyright[] =
|
||||||
|
"Copyright (c) 2011 DeforaOS Project <contact@defora.org>";
|
||||||
|
|
||||||
|
|
||||||
/* prototypes */
|
/* prototypes */
|
||||||
|
static void _phone_about(Phone * phone);
|
||||||
|
|
||||||
static int _phone_call_number(Phone * phone, char const * number);
|
static int _phone_call_number(Phone * phone, char const * number);
|
||||||
|
|
||||||
static void _phone_config_foreach(Phone * phone, char const * section,
|
static void _phone_config_foreach(Phone * phone, char const * section,
|
||||||
@ -383,6 +401,7 @@ Phone * phone_new(char const * plugin, int retry)
|
|||||||
phone->helper.config_get = _phone_config_get;
|
phone->helper.config_get = _phone_config_get;
|
||||||
phone->helper.config_set = _phone_config_set;
|
phone->helper.config_set = _phone_config_set;
|
||||||
phone->helper.error = phone_error;
|
phone->helper.error = phone_error;
|
||||||
|
phone->helper.about_dialog = _phone_about;
|
||||||
phone->helper.event = phone_event;
|
phone->helper.event = phone_event;
|
||||||
phone->helper.message = _phone_message;
|
phone->helper.message = _phone_message;
|
||||||
phone->helper.request = _phone_request;
|
phone->helper.request = _phone_request;
|
||||||
@ -393,6 +412,7 @@ Phone * phone_new(char const * plugin, int retry)
|
|||||||
/* widgets */
|
/* widgets */
|
||||||
phone->bold = pango_font_description_new();
|
phone->bold = pango_font_description_new();
|
||||||
pango_font_description_set_weight(phone->bold, PANGO_WEIGHT_BOLD);
|
pango_font_description_set_weight(phone->bold, PANGO_WEIGHT_BOLD);
|
||||||
|
phone->ab_window = NULL;
|
||||||
phone->ca_window = NULL;
|
phone->ca_window = NULL;
|
||||||
phone->en_window = NULL;
|
phone->en_window = NULL;
|
||||||
phone->en_method = MODEM_AUTHENTICATION_METHOD_NONE;
|
phone->en_method = MODEM_AUTHENTICATION_METHOD_NONE;
|
||||||
@ -1291,6 +1311,37 @@ void phone_settings_open_selected(Phone * phone)
|
|||||||
|
|
||||||
|
|
||||||
/* show */
|
/* show */
|
||||||
|
void phone_show_about(Phone * phone, gboolean show)
|
||||||
|
{
|
||||||
|
if(phone->ab_window != NULL)
|
||||||
|
{
|
||||||
|
if(show)
|
||||||
|
gtk_window_present(GTK_WINDOW(phone->ab_window));
|
||||||
|
else
|
||||||
|
gtk_widget_hide(phone->ab_window);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
phone->ab_window = desktop_about_dialog_new();
|
||||||
|
desktop_about_dialog_set_authors(phone->ab_window, _authors);
|
||||||
|
desktop_about_dialog_set_copyright(phone->ab_window, _copyright);
|
||||||
|
desktop_about_dialog_set_license(phone->ab_window, _license);
|
||||||
|
desktop_about_dialog_set_logo_icon_name(phone->ab_window,
|
||||||
|
"phone-dialer");
|
||||||
|
desktop_about_dialog_set_name(phone->ab_window, PACKAGE);
|
||||||
|
desktop_about_dialog_set_translator_credits(phone->ab_window,
|
||||||
|
_("translator-credits"));
|
||||||
|
desktop_about_dialog_set_version(phone->ab_window, VERSION);
|
||||||
|
desktop_about_dialog_set_website(phone->ab_window,
|
||||||
|
"http://www.defora.org/");
|
||||||
|
gtk_window_set_position(GTK_WINDOW(phone->ab_window),
|
||||||
|
GTK_WIN_POS_CENTER_ALWAYS);
|
||||||
|
g_signal_connect_swapped(phone->ab_window, "delete-event",
|
||||||
|
G_CALLBACK(on_phone_closex), NULL);
|
||||||
|
if(show)
|
||||||
|
gtk_window_present(GTK_WINDOW(phone->ab_window));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/* phone_show_call */
|
/* phone_show_call */
|
||||||
static void _show_call_window(Phone * phone);
|
static void _show_call_window(Phone * phone);
|
||||||
|
|
||||||
@ -2524,7 +2575,7 @@ void phone_show_system(Phone * phone, gboolean show)
|
|||||||
G_CALLBACK(_on_system_closex), phone);
|
G_CALLBACK(_on_system_closex), phone);
|
||||||
vbox = gtk_vbox_new(FALSE, 4);
|
vbox = gtk_vbox_new(FALSE, 4);
|
||||||
config = modem_get_config(phone->modem);
|
config = modem_get_config(phone->modem);
|
||||||
for(i = 0; config[i].name != NULL; i++)
|
for(i = 0; config != NULL && config[i].name != NULL; i++)
|
||||||
{
|
{
|
||||||
widget = NULL;
|
widget = NULL;
|
||||||
switch(config[i].type)
|
switch(config[i].type)
|
||||||
@ -2597,7 +2648,8 @@ static void _on_system_cancel(gpointer data)
|
|||||||
char buf[16];
|
char buf[16];
|
||||||
|
|
||||||
gtk_widget_hide(phone->sy_window);
|
gtk_widget_hide(phone->sy_window);
|
||||||
config = modem_get_config(phone->modem);
|
if((config = modem_get_config(phone->modem)) == NULL)
|
||||||
|
return;
|
||||||
for(i = 0; config[i].name != NULL; i++)
|
for(i = 0; config[i].name != NULL; i++)
|
||||||
{
|
{
|
||||||
if((widget = g_object_get_data(G_OBJECT(phone->sy_window),
|
if((widget = g_object_get_data(G_OBJECT(phone->sy_window),
|
||||||
@ -2651,7 +2703,7 @@ static void _on_system_ok(gpointer data)
|
|||||||
|
|
||||||
gtk_widget_hide(phone->sy_window);
|
gtk_widget_hide(phone->sy_window);
|
||||||
config = modem_get_config(phone->modem);
|
config = modem_get_config(phone->modem);
|
||||||
for(i = 0; config[i].name != NULL; i++)
|
for(i = 0; config != NULL && config[i].name != NULL; i++)
|
||||||
{
|
{
|
||||||
if((widget = g_object_get_data(G_OBJECT(phone->sy_window),
|
if((widget = g_object_get_data(G_OBJECT(phone->sy_window),
|
||||||
config[i].name)) == NULL)
|
config[i].name)) == NULL)
|
||||||
@ -3004,6 +3056,13 @@ void phone_write_send(Phone * phone)
|
|||||||
|
|
||||||
|
|
||||||
/* private */
|
/* private */
|
||||||
|
/* phone_about */
|
||||||
|
static void _phone_about(Phone * phone)
|
||||||
|
{
|
||||||
|
phone_show_about(phone, TRUE);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/* phone_call_number */
|
/* phone_call_number */
|
||||||
static int _phone_call_number(Phone * phone, char const * number)
|
static int _phone_call_number(Phone * phone, char const * number)
|
||||||
{
|
{
|
||||||
|
@ -63,6 +63,7 @@ void phone_dialer_hangup(Phone * phone);
|
|||||||
int phone_event(Phone * phone, PhoneEvent * event);
|
int phone_event(Phone * phone, PhoneEvent * event);
|
||||||
|
|
||||||
/* interface */
|
/* interface */
|
||||||
|
void phone_show_about(Phone * phone, gboolean show);
|
||||||
void phone_show_call(Phone * phone, gboolean show, ...); /* PhoneCall */
|
void phone_show_call(Phone * phone, gboolean show, ...); /* PhoneCall */
|
||||||
void phone_show_code(Phone * phone, gboolean show, ...); /* PhoneCode */
|
void phone_show_code(Phone * phone, gboolean show, ...); /* PhoneCode */
|
||||||
void phone_show_contacts(Phone * phone, gboolean show);
|
void phone_show_contacts(Phone * phone, gboolean show);
|
||||||
|
@ -100,8 +100,8 @@ smscrypt.so: $(smscrypt_OBJS)
|
|||||||
$(LD) -o smscrypt.so $(smscrypt_OBJS) $(smscrypt_LDFLAGS)
|
$(LD) -o smscrypt.so $(smscrypt_OBJS) $(smscrypt_LDFLAGS)
|
||||||
|
|
||||||
systray_OBJS = systray.o
|
systray_OBJS = systray.o
|
||||||
systray_CFLAGS = $(CPPFLAGSF) $(CPPFLAGS) $(CFLAGSF) $(CFLAGS) `pkg-config --cflags libDesktop`
|
systray_CFLAGS = $(CPPFLAGSF) $(CPPFLAGS) $(CFLAGSF) $(CFLAGS)
|
||||||
systray_LDFLAGS = $(LDFLAGSF) $(LDFLAGS) `pkg-config --libs libDesktop`
|
systray_LDFLAGS = $(LDFLAGSF) $(LDFLAGS)
|
||||||
|
|
||||||
systray.so: $(systray_OBJS)
|
systray.so: $(systray_OBJS)
|
||||||
$(LD) -o systray.so $(systray_OBJS) $(systray_LDFLAGS)
|
$(LD) -o systray.so $(systray_OBJS) $(systray_LDFLAGS)
|
||||||
|
@ -103,8 +103,6 @@ depends=../../include/Phone.h
|
|||||||
[systray]
|
[systray]
|
||||||
type=plugin
|
type=plugin
|
||||||
sources=systray.c
|
sources=systray.c
|
||||||
cflags=`pkg-config --cflags libDesktop`
|
|
||||||
ldflags=`pkg-config --libs libDesktop`
|
|
||||||
install=$(LIBDIR)/Phone/plugins
|
install=$(LIBDIR)/Phone/plugins
|
||||||
|
|
||||||
[systray.c]
|
[systray.c]
|
||||||
|
@ -1,18 +1,17 @@
|
|||||||
/* $Id$ */
|
/* $Id$ */
|
||||||
/* Copyright (c) 2011 Pierre Pronchery <khorben@defora.org> */
|
/* Copyright (c) 2011 Pierre Pronchery <khorben@defora.org> */
|
||||||
/* This file is part of DeforaOS Desktop Phone */
|
/* This file is part of DeforaOS Desktop Phone */
|
||||||
static char const _license[] =
|
/* This program is free software: you can redistribute it and/or modify
|
||||||
"This program is free software: you can redistribute it and/or modify\n"
|
* it under the terms of the GNU General Public License as published by
|
||||||
"it under the terms of the GNU General Public License as published by\n"
|
* the Free Software Foundation, version 3 of the License.
|
||||||
"the Free Software Foundation, version 3 of the License.\n"
|
*
|
||||||
"\n"
|
* This program is distributed in the hope that it will be useful,
|
||||||
"This program is distributed in the hope that it will be useful,\n"
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
"MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n"
|
* GNU General Public License for more details.
|
||||||
"GNU General Public License for more details.\n"
|
*
|
||||||
"\n"
|
* You should have received a copy of the GNU General Public License
|
||||||
"You should have received a copy of the GNU General Public License\n"
|
* along with this program. If not, see <http://www.gnu.org/licenses/>. */
|
||||||
"along with this program. If not, see <http://www.gnu.org/licenses/>.";
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -49,17 +48,6 @@ static void _systray_on_popup_menu(GtkStatusIcon * icon, guint button,
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/* variables */
|
|
||||||
static char const * _authors[] =
|
|
||||||
{
|
|
||||||
"Pierre Pronchery <khorben@defora.org>",
|
|
||||||
NULL
|
|
||||||
};
|
|
||||||
|
|
||||||
static char _copyright[] =
|
|
||||||
"Copyright (c) 2011 DeforaOS Project <contact@defora.org>";
|
|
||||||
|
|
||||||
|
|
||||||
/* public */
|
/* public */
|
||||||
/* variables */
|
/* variables */
|
||||||
PhonePlugin plugin =
|
PhonePlugin plugin =
|
||||||
@ -115,42 +103,11 @@ static int _systray_destroy(PhonePlugin * plugin)
|
|||||||
#if GTK_CHECK_VERSION(2, 10, 0)
|
#if GTK_CHECK_VERSION(2, 10, 0)
|
||||||
/* callbacks */
|
/* callbacks */
|
||||||
/* systray_on_activate */
|
/* systray_on_activate */
|
||||||
static gboolean _activate_on_closex(gpointer data);
|
|
||||||
|
|
||||||
static void _systray_on_activate(gpointer data)
|
static void _systray_on_activate(gpointer data)
|
||||||
{
|
{
|
||||||
PhonePlugin * plugin = data;
|
PhonePlugin * plugin = data;
|
||||||
Systray * systray = plugin->priv;
|
|
||||||
|
|
||||||
if(systray->ab_window != NULL)
|
plugin->helper->about_dialog(plugin->helper->phone);
|
||||||
{
|
|
||||||
gtk_window_present(GTK_WINDOW(systray->ab_window));
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
systray->ab_window = desktop_about_dialog_new();
|
|
||||||
desktop_about_dialog_set_authors(systray->ab_window, _authors);
|
|
||||||
desktop_about_dialog_set_copyright(systray->ab_window, _copyright);
|
|
||||||
desktop_about_dialog_set_license(systray->ab_window, _license);
|
|
||||||
desktop_about_dialog_set_logo_icon_name(systray->ab_window,
|
|
||||||
"phone-dialer");
|
|
||||||
desktop_about_dialog_set_name(systray->ab_window, PACKAGE);
|
|
||||||
desktop_about_dialog_set_version(systray->ab_window, VERSION);
|
|
||||||
desktop_about_dialog_set_website(systray->ab_window,
|
|
||||||
"http://www.defora.org/");
|
|
||||||
gtk_window_set_position(GTK_WINDOW(systray->ab_window),
|
|
||||||
GTK_WIN_POS_CENTER_ALWAYS);
|
|
||||||
g_signal_connect_swapped(systray->ab_window, "delete-event",
|
|
||||||
G_CALLBACK(_activate_on_closex), plugin);
|
|
||||||
gtk_widget_show(systray->ab_window);
|
|
||||||
}
|
|
||||||
|
|
||||||
static gboolean _activate_on_closex(gpointer data)
|
|
||||||
{
|
|
||||||
PhonePlugin * plugin = data;
|
|
||||||
Systray * systray = plugin->priv;
|
|
||||||
|
|
||||||
gtk_widget_hide(systray->ab_window);
|
|
||||||
return TRUE;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -2,7 +2,7 @@ subdirs=modems,plugins
|
|||||||
targets=phone,phonectl
|
targets=phone,phonectl
|
||||||
cppflags_force=-I ../include
|
cppflags_force=-I ../include
|
||||||
cppflags=
|
cppflags=
|
||||||
cflags_force=-W `pkg-config --cflags libSystem gtk+-2.0`
|
cflags_force=-W
|
||||||
cflags=-Wall -g -O2 -pedantic
|
cflags=-Wall -g -O2 -pedantic
|
||||||
ldflags_force=`pkg-config --libs libSystem gtk+-2.0`
|
ldflags_force=`pkg-config --libs libSystem gtk+-2.0`
|
||||||
ldflags=-L $(PREFIX)/lib -Wl,-rpath,$(PREFIX)/lib
|
ldflags=-L $(PREFIX)/lib -Wl,-rpath,$(PREFIX)/lib
|
||||||
@ -10,11 +10,15 @@ dist=Makefile,callbacks.h,modem.h,phone.h
|
|||||||
|
|
||||||
[phone]
|
[phone]
|
||||||
type=binary
|
type=binary
|
||||||
|
cflags=`pkg-config --cflags libDesktop`
|
||||||
|
ldflags=`pkg-config --libs libDesktop`
|
||||||
sources=callbacks.c,main.c,modem.c,phone.c
|
sources=callbacks.c,main.c,modem.c,phone.c
|
||||||
install=$(BINDIR)
|
install=$(BINDIR)
|
||||||
|
|
||||||
[phonectl]
|
[phonectl]
|
||||||
type=binary
|
type=binary
|
||||||
|
cflags=`pkg-config --cflags gtk+-2.0`
|
||||||
|
ldflags=`pkg-config --libs gtk+-2.0`
|
||||||
sources=phonectl.c
|
sources=phonectl.c
|
||||||
install=$(BINDIR)
|
install=$(BINDIR)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user