[
  {
    "path": ".tx/config",
    "content": "[main]\nhost = https://www.transifex.com\ntype = PO\n\n[nuntius-linux.strings]\nfile_filter = po/<lang>.po\nsource_file = po/nuntius.pot\nsource_lang = en"
  },
  {
    "path": "AUTHORS",
    "content": "Andrea Curtoni <andreacurtoni@gmail.com>\nIgnacio Casal Quinteiro <nacho.resa@gmail.com>\nPaolo Borelli <pborelli@katamail.com>\n"
  },
  {
    "path": "COPYING",
    "content": "                    GNU GENERAL PUBLIC LICENSE\n                       Version 2, June 1991\n\n Copyright (C) 1989, 1991 Free Software Foundation, Inc.,\n 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA\n Everyone is permitted to copy and distribute verbatim copies\n of this license document, but changing it is not allowed.\n\n                            Preamble\n\n  The licenses for most software are designed to take away your\nfreedom to share and change it.  By contrast, the GNU General Public\nLicense is intended to guarantee your freedom to share and change free\nsoftware--to make sure the software is free for all its users.  This\nGeneral Public License applies to most of the Free Software\nFoundation's software and to any other program whose authors commit to\nusing it.  (Some other Free Software Foundation software is covered by\nthe GNU Lesser General Public License instead.)  You can apply it to\nyour programs, too.\n\n  When we speak of free software, we are referring to freedom, not\nprice.  Our General Public Licenses are designed to make sure that you\nhave the freedom to distribute copies of free software (and charge for\nthis service if you wish), that you receive source code or can get it\nif you want it, that you can change the software or use pieces of it\nin new free programs; and that you know you can do these things.\n\n  To protect your rights, we need to make restrictions that forbid\nanyone to deny you these rights or to ask you to surrender the rights.\nThese restrictions translate to certain responsibilities for you if you\ndistribute copies of the software, or if you modify it.\n\n  For example, if you distribute copies of such a program, whether\ngratis or for a fee, you must give the recipients all the rights that\nyou have.  You must make sure that they, too, receive or can get the\nsource code.  And you must show them these terms so they know their\nrights.\n\n  We protect your rights with two steps: (1) copyright the software, and\n(2) offer you this license which gives you legal permission to copy,\ndistribute and/or modify the software.\n\n  Also, for each author's protection and ours, we want to make certain\nthat everyone understands that there is no warranty for this free\nsoftware.  If the software is modified by someone else and passed on, we\nwant its recipients to know that what they have is not the original, so\nthat any problems introduced by others will not reflect on the original\nauthors' reputations.\n\n  Finally, any free program is threatened constantly by software\npatents.  We wish to avoid the danger that redistributors of a free\nprogram will individually obtain patent licenses, in effect making the\nprogram proprietary.  To prevent this, we have made it clear that any\npatent must be licensed for everyone's free use or not licensed at all.\n\n  The precise terms and conditions for copying, distribution and\nmodification follow.\n\n                    GNU GENERAL PUBLIC LICENSE\n   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION\n\n  0. This License applies to any program or other work which contains\na notice placed by the copyright holder saying it may be distributed\nunder the terms of this General Public License.  The \"Program\", below,\nrefers to any such program or work, and a \"work based on the Program\"\nmeans either the Program or any derivative work under copyright law:\nthat is to say, a work containing the Program or a portion of it,\neither verbatim or with modifications and/or translated into another\nlanguage.  (Hereinafter, translation is included without limitation in\nthe term \"modification\".)  Each licensee is addressed as \"you\".\n\nActivities other than copying, distribution and modification are not\ncovered by this License; they are outside its scope.  The act of\nrunning the Program is not restricted, and the output from the Program\nis covered only if its contents constitute a work based on the\nProgram (independent of having been made by running the Program).\nWhether that is true depends on what the Program does.\n\n  1. You may copy and distribute verbatim copies of the Program's\nsource code as you receive it, in any medium, provided that you\nconspicuously and appropriately publish on each copy an appropriate\ncopyright notice and disclaimer of warranty; keep intact all the\nnotices that refer to this License and to the absence of any warranty;\nand give any other recipients of the Program a copy of this License\nalong with the Program.\n\nYou may charge a fee for the physical act of transferring a copy, and\nyou may at your option offer warranty protection in exchange for a fee.\n\n  2. You may modify your copy or copies of the Program or any portion\nof it, thus forming a work based on the Program, and copy and\ndistribute such modifications or work under the terms of Section 1\nabove, provided that you also meet all of these conditions:\n\n    a) You must cause the modified files to carry prominent notices\n    stating that you changed the files and the date of any change.\n\n    b) You must cause any work that you distribute or publish, that in\n    whole or in part contains or is derived from the Program or any\n    part thereof, to be licensed as a whole at no charge to all third\n    parties under the terms of this License.\n\n    c) If the modified program normally reads commands interactively\n    when run, you must cause it, when started running for such\n    interactive use in the most ordinary way, to print or display an\n    announcement including an appropriate copyright notice and a\n    notice that there is no warranty (or else, saying that you provide\n    a warranty) and that users may redistribute the program under\n    these conditions, and telling the user how to view a copy of this\n    License.  (Exception: if the Program itself is interactive but\n    does not normally print such an announcement, your work based on\n    the Program is not required to print an announcement.)\n\nThese requirements apply to the modified work as a whole.  If\nidentifiable sections of that work are not derived from the Program,\nand can be reasonably considered independent and separate works in\nthemselves, then this License, and its terms, do not apply to those\nsections when you distribute them as separate works.  But when you\ndistribute the same sections as part of a whole which is a work based\non the Program, the distribution of the whole must be on the terms of\nthis License, whose permissions for other licensees extend to the\nentire whole, and thus to each and every part regardless of who wrote it.\n\nThus, it is not the intent of this section to claim rights or contest\nyour rights to work written entirely by you; rather, the intent is to\nexercise the right to control the distribution of derivative or\ncollective works based on the Program.\n\nIn addition, mere aggregation of another work not based on the Program\nwith the Program (or with a work based on the Program) on a volume of\na storage or distribution medium does not bring the other work under\nthe scope of this License.\n\n  3. You may copy and distribute the Program (or a work based on it,\nunder Section 2) in object code or executable form under the terms of\nSections 1 and 2 above provided that you also do one of the following:\n\n    a) Accompany it with the complete corresponding machine-readable\n    source code, which must be distributed under the terms of Sections\n    1 and 2 above on a medium customarily used for software interchange; or,\n\n    b) Accompany it with a written offer, valid for at least three\n    years, to give any third party, for a charge no more than your\n    cost of physically performing source distribution, a complete\n    machine-readable copy of the corresponding source code, to be\n    distributed under the terms of Sections 1 and 2 above on a medium\n    customarily used for software interchange; or,\n\n    c) Accompany it with the information you received as to the offer\n    to distribute corresponding source code.  (This alternative is\n    allowed only for noncommercial distribution and only if you\n    received the program in object code or executable form with such\n    an offer, in accord with Subsection b above.)\n\nThe source code for a work means the preferred form of the work for\nmaking modifications to it.  For an executable work, complete source\ncode means all the source code for all modules it contains, plus any\nassociated interface definition files, plus the scripts used to\ncontrol compilation and installation of the executable.  However, as a\nspecial exception, the source code distributed need not include\nanything that is normally distributed (in either source or binary\nform) with the major components (compiler, kernel, and so on) of the\noperating system on which the executable runs, unless that component\nitself accompanies the executable.\n\nIf distribution of executable or object code is made by offering\naccess to copy from a designated place, then offering equivalent\naccess to copy the source code from the same place counts as\ndistribution of the source code, even though third parties are not\ncompelled to copy the source along with the object code.\n\n  4. You may not copy, modify, sublicense, or distribute the Program\nexcept as expressly provided under this License.  Any attempt\notherwise to copy, modify, sublicense or distribute the Program is\nvoid, and will automatically terminate your rights under this License.\nHowever, parties who have received copies, or rights, from you under\nthis License will not have their licenses terminated so long as such\nparties remain in full compliance.\n\n  5. You are not required to accept this License, since you have not\nsigned it.  However, nothing else grants you permission to modify or\ndistribute the Program or its derivative works.  These actions are\nprohibited by law if you do not accept this License.  Therefore, by\nmodifying or distributing the Program (or any work based on the\nProgram), you indicate your acceptance of this License to do so, and\nall its terms and conditions for copying, distributing or modifying\nthe Program or works based on it.\n\n  6. Each time you redistribute the Program (or any work based on the\nProgram), the recipient automatically receives a license from the\noriginal licensor to copy, distribute or modify the Program subject to\nthese terms and conditions.  You may not impose any further\nrestrictions on the recipients' exercise of the rights granted herein.\nYou are not responsible for enforcing compliance by third parties to\nthis License.\n\n  7. If, as a consequence of a court judgment or allegation of patent\ninfringement or for any other reason (not limited to patent issues),\nconditions are imposed on you (whether by court order, agreement or\notherwise) that contradict the conditions of this License, they do not\nexcuse you from the conditions of this License.  If you cannot\ndistribute so as to satisfy simultaneously your obligations under this\nLicense and any other pertinent obligations, then as a consequence you\nmay not distribute the Program at all.  For example, if a patent\nlicense would not permit royalty-free redistribution of the Program by\nall those who receive copies directly or indirectly through you, then\nthe only way you could satisfy both it and this License would be to\nrefrain entirely from distribution of the Program.\n\nIf any portion of this section is held invalid or unenforceable under\nany particular circumstance, the balance of the section is intended to\napply and the section as a whole is intended to apply in other\ncircumstances.\n\nIt is not the purpose of this section to induce you to infringe any\npatents or other property right claims or to contest validity of any\nsuch claims; this section has the sole purpose of protecting the\nintegrity of the free software distribution system, which is\nimplemented by public license practices.  Many people have made\ngenerous contributions to the wide range of software distributed\nthrough that system in reliance on consistent application of that\nsystem; it is up to the author/donor to decide if he or she is willing\nto distribute software through any other system and a licensee cannot\nimpose that choice.\n\nThis section is intended to make thoroughly clear what is believed to\nbe a consequence of the rest of this License.\n\n  8. If the distribution and/or use of the Program is restricted in\ncertain countries either by patents or by copyrighted interfaces, the\noriginal copyright holder who places the Program under this License\nmay add an explicit geographical distribution limitation excluding\nthose countries, so that distribution is permitted only in or among\ncountries not thus excluded.  In such case, this License incorporates\nthe limitation as if written in the body of this License.\n\n  9. The Free Software Foundation may publish revised and/or new versions\nof the General Public License from time to time.  Such new versions will\nbe similar in spirit to the present version, but may differ in detail to\naddress new problems or concerns.\n\nEach version is given a distinguishing version number.  If the Program\nspecifies a version number of this License which applies to it and \"any\nlater version\", you have the option of following the terms and conditions\neither of that version or of any later version published by the Free\nSoftware Foundation.  If the Program does not specify a version number of\nthis License, you may choose any version ever published by the Free Software\nFoundation.\n\n  10. If you wish to incorporate parts of the Program into other free\nprograms whose distribution conditions are different, write to the author\nto ask for permission.  For software which is copyrighted by the Free\nSoftware Foundation, write to the Free Software Foundation; we sometimes\nmake exceptions for this.  Our decision will be guided by the two goals\nof preserving the free status of all derivatives of our free software and\nof promoting the sharing and reuse of software generally.\n\n                            NO WARRANTY\n\n  11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY\nFOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.  EXCEPT WHEN\nOTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES\nPROVIDE THE PROGRAM \"AS IS\" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED\nOR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF\nMERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.  THE ENTIRE RISK AS\nTO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.  SHOULD THE\nPROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,\nREPAIR OR CORRECTION.\n\n  12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING\nWILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR\nREDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,\nINCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING\nOUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED\nTO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY\nYOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER\nPROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE\nPOSSIBILITY OF SUCH DAMAGES.\n\n                     END OF TERMS AND CONDITIONS\n\n            How to Apply These Terms to Your New Programs\n\n  If you develop a new program, and you want it to be of the greatest\npossible use to the public, the best way to achieve this is to make it\nfree software which everyone can redistribute and change under these terms.\n\n  To do so, attach the following notices to the program.  It is safest\nto attach them to the start of each source file to most effectively\nconvey the exclusion of warranty; and each file should have at least\nthe \"copyright\" line and a pointer to where the full notice is found.\n\n    <one line to give the program's name and a brief idea of what it does.>\n    Copyright (C) <year>  <name of author>\n\n    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\n    the Free Software Foundation; either version 2 of the License, or\n    (at your option) any later version.\n\n    This program is distributed in the hope that it will be useful,\n    but WITHOUT ANY WARRANTY; without even the implied warranty of\n    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n    GNU General Public License for more details.\n\n    You should have received a copy of the GNU General Public License along\n    with this program; if not, write to the Free Software Foundation, Inc.,\n    51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.\n\nAlso add information on how to contact you by electronic and paper mail.\n\nIf the program is interactive, make it output a short notice like this\nwhen it starts in an interactive mode:\n\n    Gnomovision version 69, Copyright (C) year name of author\n    Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.\n    This is free software, and you are welcome to redistribute it\n    under certain conditions; type `show c' for details.\n\nThe hypothetical commands `show w' and `show c' should show the appropriate\nparts of the General Public License.  Of course, the commands you use may\nbe called something other than `show w' and `show c'; they could even be\nmouse-clicks or menu items--whatever suits your program.\n\nYou should also get your employer (if you work as a programmer) or your\nschool, if any, to sign a \"copyright disclaimer\" for the program, if\nnecessary.  Here is a sample; alter the names:\n\n  Yoyodyne, Inc., hereby disclaims all copyright interest in the program\n  `Gnomovision' (which makes passes at compilers) written by James Hacker.\n\n  <signature of Ty Coon>, 1 April 1989\n  Ty Coon, President of Vice\n\nThis General Public License does not permit incorporating your program into\nproprietary programs.  If your program is a subroutine library, you may\nconsider it more useful to permit linking proprietary applications with the\nlibrary.  If this is what you want to do, use the GNU Lesser General\nPublic License instead of this License.\n\n"
  },
  {
    "path": "Makefile.am",
    "content": "ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}\n\nSUBDIRS = po\n\n# desktop file\ndesktopdir = $(datadir)/applications\ndesktop_in_files = data/org.holylobster.nuntius.desktop.in\ndesktop_DATA = $(desktop_in_files:.desktop.in=.desktop)\n@INTLTOOL_DESKTOP_RULE@\n\n# autostart file\nautostartdir = $(sysconfdir)/xdg/autostart\nautostart_DATA = $(desktop_DATA)\n\n# appdata file\nappdatadir = $(datadir)/appdata\nappdata_DATA = $(appdata_in_files:.xml.in=.xml)\nappdata_in_files = data/org.holylobster.nuntius.appdata.xml.in\n@INTLTOOL_XML_RULE@\n\n# DBus service file\nservicedir = $(datadir)/dbus-1/services\nservice_DATA = data/org.holylobster.nuntius.service\ndist_noinst_DATA = data/org.holylobster.nuntius.service.in\n\ndata/org.holylobster.nuntius.service: data/org.holylobster.nuntius.service.in Makefile\n\t$(AM_V_GEN) $(MKDIR_P) $(dir $@); sed -e \"s|\\@bindir\\@|$(bindir)|\" $< > $@\n\n# gsettings\ngsettings_SCHEMAS = data/org.holylobster.nuntius.gschema.xml\n@GSETTINGS_RULES@\n\ndata_icons_public_icons = \\\n\thicolor_apps_16x16_nuntius.png \\\n\thicolor_apps_22x22_nuntius.png \\\n\thicolor_apps_24x24_nuntius.png \\\n\thicolor_apps_32x32_nuntius.png \\\n\thicolor_apps_48x48_nuntius.png \\\n\thicolor_apps_256x256_nuntius.png\n\ndata-icons-install-icons:\n\t@echo \"Installing icons\"; \\\n\tfor icon in $(data_icons_public_icons); do \\\n\t\tTHEME=`echo $$icon | cut -d_ -f1`; \\\n\t\tCONTEXT=`echo $$icon | cut -d_ -f2`; \\\n\t\tSIZE=`echo $$icon | cut -d_ -f3`; \\\n\t\tICONFILE=`echo $$icon | cut -d_ -f4`; \\\n\t\t$(mkinstalldirs) $(DESTDIR)$(datadir)/icons/$$THEME/$$SIZE/$$CONTEXT; \\\n\t\techo \"  - $(DESTDIR)$(datadir)/icons/$$THEME/$$SIZE/$$CONTEXT/$$ICONFILE\"; \\\n\t\t$(INSTALL_DATA) $(srcdir)/data/icons/$$icon $(DESTDIR)$(datadir)/icons/$$THEME/$$SIZE/$$CONTEXT/$$ICONFILE; \\\n\tdone;\n\ndata-icons-uninstall-icons:\n\t-for icon in $(data_icons_public_icons); do \\\n\t\tTHEME=`echo $$icon | cut -d_ -f1`; \\\n\t\tCONTEXT=`echo $$icon | cut -d_ -f2`; \\\n\t\tSIZE=`echo $$icon | cut -d_ -f3`; \\\n\t\tICONFILE=`echo $$icon | cut -d_ -f4`; \\\n\t\trm -f $(DESTDIR)$(datadir)/icons/$$THEME/$$SIZE/$$CONTEXT/$$ICONFILE; \\\n\tdone;\n\nAM_CPPFLAGS = \\\n\t-DGETTEXT_PACKAGE=\\\"\"$(GETTEXT_PACKAGE)\"\\\" \\\n\t-DGNOMELOCALEDIR=\\\"\"$(localedir)\"\\\" \\\n\t-DDATADIR=\\\"\"$(datadir)\"\\\" \\\n\t-DTOOLSDIR=\\\"\"$(libexecdir)/$(PACKAGE)\"\\\"\n\nAM_VALAFLAGS = \\\n\t--target-glib=2.40 \\\n\t--pkg gio-2.0 \\\n\t--pkg gio-unix-2.0 \\\n\t--pkg gtk+-3.0 \\\n\t--pkg json-glib-1.0 \\\n\t--pkg posix \\\n\t--gresources  $(top_srcdir)/src/resources/nuntius.gresource.xml\n\nbin_PROGRAMS = nuntius qrtest\n\nBUILT_SOURCES = \\\n\tsrc/resources.c\n\nresource_files = $(shell $(GLIB_COMPILE_RESOURCES) --generate-dependencies --sourcedir=$(top_srcdir)/src/resources $(top_srcdir)/src/resources/nuntius.gresource.xml)\nsrc/resources.c: $(top_srcdir)/src/resources/nuntius.gresource.xml $(resource_files)\n\t$(AM_V_GEN) $(GLIB_COMPILE_RESOURCES) --target=$@ --sourcedir=$(top_srcdir)/src/resources --generate-source $<\n\ntoolsdir = $(libexecdir)/$(PACKAGE)\ntools_SCRIPTS = createcert.sh\n\nVALA_SOURCES = \\\n\tsrc/application.vala \\\n\tsrc/appslistpanel.vala \\\n\tsrc/appslist.vala \\\n\tsrc/connection.vala \\\n\tsrc/notification.vala \\\n\tsrc/notificationapp.vala \\\n\tsrc/notificationcounter.vala \\\n\tsrc/notificationsview.vala \\\n\tsrc/qrimage.vala \\\n\tsrc/smsnotification.vala \\\n\tsrc/testview.vala \\\n\tsrc/window.vala \\\n\tsrc/main.vala\n\nnuntius_SOURCES = \\\n\t$(BUILT_SOURCES) \\\n\t$(VALA_SOURCES) \\\n\tsrc/config.vapi \\\n\tsrc/qrencode.vapi\n\nAM_CFLAGS = \\\n\t$(NUNTIUS_CFLAGS) \\\n\t-Wall \\\n\t-Wno-unused-but-set-variable \\\n\t-Wno-unused-variable\n\nnuntius_LDFLAGS = -export-dynamic\nnuntius_LDADD = \\\n\t$(NUNTIUS_LIBS) \\\n\t-lm\n\nqrtest_SOURCES = \\\n\ttests/qrtest.vala \\\n\tsrc/qrimage.vala \\\n\tsrc/qrencode.vapi\n\nqrtest_LDFLAGS = -export-dynamic\nqrtest_LDADD = \\\n\t$(NUNTIUS_LIBS) \\\n\t-lm\n\ncheck-local: $(desktop_DATA)\n\t$(DESKTOP_FILE_VALIDATE) $(desktop_DATA)\n\ninstall-data-local: data-icons-install-icons\n\nuninstall-local: data-icons-uninstall-icons\n\nEXTRA_DIST = \\\n\t$(appdata_in_files) \\\n\t$(desktop_in_files) \\\n\t$(resource_files) \\\n\tsrc/resources/nuntius.gresource.xml \\\n\t$(addprefix data/icons/,$(data_icons_public_icons))\n\nCLEANFILES = \\\n\t$(appdata_DATA) \\\n\t$(desktop_DATA) \\\n\t$(service_DATA)\n\nMAINTAINERCLEANFILES = \\\n\tABOUT-NLS \\\n\taclocal.m4 \\\n\tconfig.guess \\\n\tconfig.h.in \\\n\tconfig.rpath \\\n\tconfig.sub \\\n\tdepcomp \\\n\tinstall-sh \\\n\tltmain.sh \\\n\tmissing \\\n\tcompile \\\n\t$(VALA_SOURCES:.vala=.c) \\\n\t*.stamp\n\n-include $(top_srcdir)/git.mk\n"
  },
  {
    "path": "NEWS",
    "content": "=============\nnuntius 0.2.0\n=============\n\nNew Features and Fixes\n======================\n- Added user interface\n- Added translation support\n- Misc bugfixes\n\n=============\nnuntius 0.1.0\n=============\n\nNew Features and Fixes\n======================\n- Added appdata\n- Added translation support\n- Use DBusObjectManager instead of custom implementation\n- Misc bugfixes\n\n=============\nnuntius 0.0.1\n=============\n\nInitial Release.\n"
  },
  {
    "path": "README.md",
    "content": "Nuntius\n===================================\n\n## Introduction\nNuntius delivers notifications from your phone or tablet to your computer over Bluetooth.\n\nNuntius is an Open Source project from HolyLobster.\n\nTo use Nuntius you will need to install a companion tool on your phone or tablet and pair it via Bluetooth.\nYou will also need to restart your session to auto-start nuntius.\n\nFor more information on the project and the companion tools to install on the computer check https://github.com/holylobster\n\n## The Icon\nYou may have questions on the icon. Nice shot.\nIn fact most of the Nuntius development time has been spent on the icon design concept.\nIf you have suggestions on how to improve it we are very open... but... we think it is hardly possible to do better than this.\n\n## Packages\nYou can install Nuntius from:\n\n * Fedora: `dnf install nuntius` (use `yum` instead of `dnf` on Fedora <= 21)\n * [Arch Linux (AUR)](https://aur.archlinux.org/packages/nuntius/)\n\nYou will need to install Nuntius also on your phone or tablet.\n\nAt the moment Nuntius is available for Android, check here\n\n * https://github.com/holylobster/nuntius-android\n\n## Getting in touch\nWe have an IRC channel: #nuntius on the irc.gnome.org server.\nFeel free to join and talk to us! Note that the channel is new and there are not many people (yet!) so be patient and hang around if you do not receive a reply immediately.\n\n## Some tips to debug\n * Launch the bluetooth dameon as \"sudo  /usr/libexec/bluetooth/bluetoothd -d -n\"\n * Using bluetoothctl\n   * I had to set \"agent on\", \"default-agent\" and \"trust 98:D6:F7:73:03:F1\"\n   * Having it running it will provide some information\n * /var/log/messages gives also some information about bluetoothd if you do not run it directly\n * run \"sudo btmon > btmon.log\" to get information from the devices that try to connect to the computer\n   * This is very useful to see to which uuid is trying to connect and what kind of errors it gets\n\n"
  },
  {
    "path": "autogen.sh",
    "content": "#!/bin/sh\n# Run this to generate all the initial makefiles, etc.\n\ntest -n \"$srcdir\" || srcdir=`dirname \"$0\"`\ntest -n \"$srcdir\" || srcdir=.\n\nOLDDIR=`pwd`\ncd $srcdir\n\nAUTORECONF=`which autoreconf`\nif test -z $AUTORECONF; then\n    echo \"*** No autoreconf found, please install it ***\"\n    exit 1\nfi\n\nINTLTOOLIZE=`which intltoolize`\nif test -z $INTLTOOLIZE; then\n    echo \"*** No intltoolize found, please install the intltool package ***\"\n    exit 1\nfi\n\ngit submodule update --init --recursive\n\nautopoint --force || exit $?\nAUTOPOINT='intltoolize --automake --copy' autoreconf --force --install --verbose\n\ncd $OLDDIR\ntest -n \"$NOCONFIGURE\" || \"$srcdir/configure\" \"$@\"\n"
  },
  {
    "path": "configure.ac",
    "content": "AC_PREREQ(2.63)\n\nAC_INIT([nuntius], [0.2.0])\n\ndnl http://people.gnome.org/~walters/docs/build-api.txt\ndnl We don't support separate builddir when building from git\necho \\#buildapi-variable-no-builddir >/dev/null\n\nAC_CONFIG_MACRO_DIR([m4])\nAC_CONFIG_HEADERS(config.h)\nAC_CONFIG_SRCDIR(src/main.vala)\n\nAM_INIT_AUTOMAKE([1.11 tar-ustar dist-xz no-dist-gzip foreign])\nm4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])])\n\nIT_PROG_INTLTOOL([0.50.1])\nAM_GNU_GETTEXT([external])\nAM_GNU_GETTEXT_VERSION([0.17])\nGETTEXT_PACKAGE=AC_PACKAGE_NAME\nAC_SUBST([GETTEXT_PACKAGE])\nAC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,\"$GETTEXT_PACKAGE\",[The name of the gettext domain])\n\nAC_PROG_CC\nAC_PROG_CC_STDC\nAC_PROG_INSTALL\nAM_PROG_VALAC([0.23.3])\n\nAC_PATH_PROG(DESKTOP_FILE_VALIDATE, desktop-file-validate, /bin/true)\nAC_PATH_PROG(GLIB_COMPILE_RESOURCES, glib-compile-resources)\n\nGLIB_GSETTINGS\n\nPKG_PROG_PKG_CONFIG\n\nPKG_CHECK_MODULES(NUNTIUS, [\n    gio-2.0 >= 2.40\n    gio-unix-2.0 >= 2.38\n    glib-2.0 >= 2.38\n    gtk+-3.0 >= 3.14.0\n    json-glib-1.0 >= 0.16.2\n    libqrencode >= 3.1.0\n])\n\nAC_CONFIG_FILES([\n    Makefile\n    data/org.holylobster.nuntius.gschema.xml\n    po/Makefile.in\n])\n\nAC_OUTPUT\n\necho \"\n    nuntius ${VERSION}\n\n    prefix: ${prefix}\n    Vala compiler: ${VALAC}\n    C compiler: ${CC}\n\n    Now type 'make' to build ${PACKAGE}\n\"\n"
  },
  {
    "path": "createcert.sh",
    "content": "#!/bin/bash\n\nfunction try {\n    \"$@\"\n    local status=$?\n    if [ $status -ne 0 ]; then\n        echo -e \"\\nError with $1\" >&2\n        exit $?\n    fi\n    return $status\n}\n\nfunction create_cert() {\n    if [[ ! -f $HOME/.config/nuntius/nuntius.pem || ! -f $HOME/.config/nuntius/nuntius.key ]]; then\n        echo \"Creating cert...\"\n        cd $HOME/.config/nuntius\n        try openssl genrsa -out nuntius.key 2048\n        try openssl req -new -key nuntius.key -out nuntius.csr -subj \"/O=Holylobster/OU=Nuntius\"\n        try openssl x509 -req -days 3650 -in nuntius.csr -signkey nuntius.key -out nuntius.crt\n        try openssl x509 -in nuntius.crt -out nuntius.pem\n        exit $?\n    else\n        echo \"Certificate already exist...\"\n        exit 0\n    fi\n}\n\nif [[ ! -d $HOME/.config/nuntius ]]; then\n    echo \"Creating nuntius config directory...\"\n    mkdir -p $HOME/.config/nuntius\nfi\n\ncreate_cert\n\n# ex:set ts=4 et:\n"
  },
  {
    "path": "data/icons/render-bitmaps.rb",
    "content": "#!/usr/bin/env ruby\n\nrequire \"rexml/document\"\nrequire \"fileutils\"\ninclude REXML\nINKSCAPE = '/usr/bin/inkscape'\nSRC = \"./\"\n\ndef renderit(file,explicit)\n  svg = Document.new(File.new(\"#{SRC}/#{file}\", 'r'))\n  #puts \"DEBUG: #{file}\"\n  svg.root.each_element(\"//g[contains(@inkscape:label,'baseplate')]\") do |icon|\n    if icon.attributes['inkscape:groupmode']=='layer' #only look inside layers, there may be pasted groups\n      context = icon.elements[\"text[@inkscape:label='context']/tspan\"].nil? ? 'blank' : icon.elements[\"text[@inkscape:label='context']/tspan\"].text\n      icon_name = icon.elements[\"text[@inkscape:label='icon-name']/tspan\"].nil? ? 'blank' : icon.elements[\"text[@inkscape:label='icon-name']/tspan\"].text\n      puts \"#{file}:#{icon.attributes['inkscape:label']}  #{context}/#{icon_name}\"\n      icon.each_element(\"rect\") do |box|\n        dir = \"hicolor/#{box.attributes['width']}x#{box.attributes['height']}/#{context}\"\n        out = \"#{dir}/#{icon_name.gsub(/$/,'.png')}\"\n        cmd = \"#{INKSCAPE} -i #{box.attributes['id']} -e #{out} #{SRC}/#{file} > /dev/null 2>&1\"\n        FileUtils.makedirs(dir) unless File.exists?(dir)\n        if (!explicit && File.exists?(out))\n          print \"-\" #skip if PNG exists\n        elsif (box.attributes['width']==\"256\")\n          system(cmd)\n          print \".\"\n          dir = \"hicolor/512x512/#{context}\"\n          out = \"#{dir}/#{icon_name.gsub(/$/,'.png')}\"\n          cmd = \"#{INKSCAPE} -i #{box.attributes['id']} -d 180 -e #{out} #{SRC}/#{file} > /dev/null 2>&1\"\n          system(cmd)\n          print \"*\"          \n        else\n          system(cmd)\n          print \".\"\n        end\n      end\n      puts ''\n    end\n  end\nend\n\nif (ARGV[0].nil?) #render all SVGs\n  system(\"mkdir hicolor/\") unless File.exists?('hicolor')\n  puts \"Rendering from SVGs in #{SRC}\"\n  Dir.foreach(SRC) do |file|\n    renderit(file, false) if file.match(/svg$/)\n  end\n  puts \"\\nrendered all SVGs\"\nelse #only render the SVG passed\n  file = \"#{ARGV[0]}.svg\"\n  if (File.exists?(\"#{SRC}/#{file}\"))\n    renderit(file, true)\n    puts \"\\nrendered #{file}\"\n  else\n    puts \"[E] No such file (#{file})\"\n  end\nend\n"
  },
  {
    "path": "data/org.holylobster.nuntius.appdata.xml.in",
    "content": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!-- Copyright 2015 Ignacio Casal Quinteiro <icq@gnome.org> -->\n<application>\n  <id type=\"desktop\">org.holylobster.nuntius.desktop</id>\n  <metadata_license>CC0</metadata_license>\n  <project_license>GPL-2.0+</project_license>\n  <description>\n    <_p>\n      Nuntius delivers notifications from your phone or tablet to your computer\n      over Bluetooth.\n    </_p>\n    <_p>\n      To use Nuntius you will need to install a companion tool on your phone or\n      tablet and pair it via Bluetooth.\n    </_p>\n  </description>\n  <screenshots>\n    <screenshot type=\"default\">https://raw.githubusercontent.com/holylobster/nuntius-android/master/store-stuff/play-store-feature.jpg</screenshot>\n  </screenshots>\n  <url type=\"homepage\">https://github.com/orgs/holylobster</url>\n  <updatecontact>icq@gnome.org</updatecontact>\n</application>\n"
  },
  {
    "path": "data/org.holylobster.nuntius.desktop.in",
    "content": "[Desktop Entry]\nName=Nuntius\nGenericName=Nuntius\nX-GNOME-FullName=Nuntius\n_Comment=Deliver notifications from your phone or tablet to your computer over Bluetooth\n_Keywords=notifications;\nExec=nuntius\nTerminal=false\nType=Application\nIcon=nuntius\nCategories=GNOME;GTK;Utility;\nStartupNotify=true\nDBusActivatable=true\nX-GNOME-Autostart-enabled=true\nX-GNOME-UsesNotifications=true\n"
  },
  {
    "path": "data/org.holylobster.nuntius.gschema.xml.in",
    "content": "<schemalist gettext-domain=\"@GETTEXT_PACKAGE@\">\n  <schema id=\"org.holylobster.nuntius.state\" path=\"/org/holylobster/nuntius/state/\">\n    <child schema=\"org.holylobster.nuntius.state.window\" name=\"window\"/>\n  </schema>\n  <schema id=\"org.holylobster.nuntius.state.window\" path=\"/org/holylobster/nuntius/state/window/\">\n    <key type=\"i\" name=\"state\">\n      <default>0</default>\n      <summary>Window state</summary>\n      <description>\n        State of the window, e.g. maximized.\n      </description>\n    </key>\n    <key type=\"(ii)\" name=\"size\">\n      <default>(870, 690)</default>\n      <summary>Window width and height</summary>\n      <description>\n        Width and height of the window.\n      </description>\n    </key>\n  </schema>\n</schemalist>\n"
  },
  {
    "path": "data/org.holylobster.nuntius.service.in",
    "content": "[D-BUS Service]\nName=org.holylobster.nuntius\nExec=@bindir@/nuntius --gapplication-service\n"
  },
  {
    "path": "git.mk",
    "content": "# git.mk\n#\n# Copyright 2009, Red Hat, Inc.\n# Copyright 2010,2011,2012,2013 Behdad Esfahbod\n# Written by Behdad Esfahbod\n#\n# Copying and distribution of this file, with or without modification,\n# is permitted in any medium without royalty provided the copyright\n# notice and this notice are preserved.\n#\n# The latest version of this file can be downloaded from:\nGIT_MK_URL = https://raw.github.com/behdad/git.mk/master/git.mk\n#\n# Bugs, etc, should be reported upstream at:\n#   https://github.com/behdad/git.mk\n#\n# To use in your project, import this file in your git repo's toplevel,\n# then do \"make -f git.mk\".  This modifies all Makefile.am files in\n# your project to -include git.mk.  Remember to add that line to new\n# Makefile.am files you create in your project, or just rerun the\n# \"make -f git.mk\".\n#\n# This enables automatic .gitignore generation.  If you need to ignore\n# more files, add them to the GITIGNOREFILES variable in your Makefile.am.\n# But think twice before doing that.  If a file has to be in .gitignore,\n# chances are very high that it's a generated file and should be in one\n# of MOSTLYCLEANFILES, CLEANFILES, DISTCLEANFILES, or MAINTAINERCLEANFILES.\n#\n# The only case that you need to manually add a file to GITIGNOREFILES is\n# when remove files in one of mostlyclean-local, clean-local, distclean-local,\n# or maintainer-clean-local make targets.\n#\n# Note that for files like editor backup, etc, there are better places to\n# ignore them.  See \"man gitignore\".\n#\n# If \"make maintainer-clean\" removes the files but they are not recognized\n# by this script (that is, if \"git status\" shows untracked files still), send\n# me the output of \"git status\" as well as your Makefile.am and Makefile for\n# the directories involved and I'll diagnose.\n#\n# For a list of toplevel files that should be in MAINTAINERCLEANFILES, see\n# Makefile.am.sample in the git.mk git repo.\n#\n# Don't EXTRA_DIST this file.  It is supposed to only live in git clones,\n# not tarballs.  It serves no useful purpose in tarballs and clutters the\n# build dir.\n#\n# This file knows how to handle autoconf, automake, libtool, gtk-doc,\n# gnome-doc-utils, yelp.m4, mallard, intltool, gsettings, dejagnu, appdata,\n# appstream.\n#\n# This makefile provides the following targets:\n#\n# - all: \"make all\" will build all gitignore files.\n# - gitignore: makes all gitignore files in the current dir and subdirs.\n# - .gitignore: make gitignore file for the current dir.\n# - gitignore-recurse: makes all gitignore files in the subdirs.\n#\n# KNOWN ISSUES:\n#\n# - Recursive configure doesn't work as $(top_srcdir)/git.mk inside the\n#   submodule doesn't find us.  If you have configure.{in,ac} files in\n#   subdirs, add a proxy git.mk file in those dirs that simply does:\n#   \"include $(top_srcdir)/../git.mk\".  Add more ..'s to your taste.\n#   And add those files to git.  See vte/gnome-pty-helper/git.mk for\n#   example.\n#\n\n\n\n###############################################################################\n# Variables user modules may want to add to toplevel MAINTAINERCLEANFILES:\n###############################################################################\n\n#\n# Most autotools-using modules should be fine including this variable in their\n# toplevel MAINTAINERCLEANFILES:\nGITIGNORE_MAINTAINERCLEANFILES_TOPLEVEL = \\\n\t$(srcdir)/aclocal.m4 \\\n\t$(srcdir)/autoscan.log \\\n\t$(srcdir)/configure.scan \\\n\t`AUX_DIR=$(srcdir)/$$(cd $(top_srcdir); $(AUTOCONF) --trace 'AC_CONFIG_AUX_DIR:$$1' ./configure.ac); \\\n\t test \"x$$AUX_DIR\" = \"x$(srcdir)/\" && AUX_DIR=$(srcdir); \\\n\t for x in \\\n\t\tar-lib \\\n\t\tcompile \\\n\t\tconfig.guess \\\n\t\tconfig.sub \\\n\t\tdepcomp \\\n\t\tinstall-sh \\\n\t\tltmain.sh \\\n\t\tmissing \\\n\t\tmkinstalldirs \\\n\t\ttest-driver \\\n\t\tylwrap \\\n\t ; do echo \"$$AUX_DIR/$$x\"; done` \\\n\t`cd $(top_srcdir); $(AUTOCONF) --trace 'AC_CONFIG_HEADERS:$$1' ./configure.ac | \\\n\thead -n 1 | while read f; do echo \"$(srcdir)/$$f.in\"; done`\n#\n# All modules should also be fine including the following variable, which\n# removes automake-generated Makefile.in files:\nGITIGNORE_MAINTAINERCLEANFILES_MAKEFILE_IN = \\\n\t`cd $(top_srcdir); $(AUTOCONF) --trace 'AC_CONFIG_FILES:$$1' ./configure.ac | \\\n\twhile read f; do \\\n\t  case $$f in Makefile|*/Makefile) \\\n\t    test -f \"$(srcdir)/$$f.am\" && echo \"$(srcdir)/$$f.in\";; esac; \\\n\tdone`\n#\n# Modules that use libtool and use  AC_CONFIG_MACRO_DIR() may also include this,\n# though it's harmless to include regardless.\nGITIGNORE_MAINTAINERCLEANFILES_M4_LIBTOOL = \\\n\t`MACRO_DIR=$(srcdir)/$$(cd $(top_srcdir); $(AUTOCONF) --trace 'AC_CONFIG_MACRO_DIR:$$1' ./configure.ac); \\\n\t if test \"x$$MACRO_DIR\" != \"x$(srcdir)/\"; then \\\n\t\tfor x in \\\n\t\t\tlibtool.m4 \\\n\t\t\tltoptions.m4 \\\n\t\t\tltsugar.m4 \\\n\t\t\tltversion.m4 \\\n\t\t\tlt~obsolete.m4 \\\n\t\t; do echo \"$$MACRO_DIR/$$x\"; done; \\\n\t fi`\n\n\n\n###############################################################################\n# Default rule is to install ourselves in all Makefile.am files:\n###############################################################################\n\ngit-all: git-mk-install\n\ngit-mk-install:\n\t@echo \"Installing git makefile\"\n\t@any_failed=; \\\n\t\tfind \"`test -z \"$(top_srcdir)\" && echo . || echo \"$(top_srcdir)\"`\" -name Makefile.am | while read x; do \\\n\t\tif grep 'include .*/git.mk' $$x >/dev/null; then \\\n\t\t\techo \"$$x already includes git.mk\"; \\\n\t\telse \\\n\t\t\tfailed=; \\\n\t\t\techo \"Updating $$x\"; \\\n\t\t\t{ cat $$x; \\\n\t\t\t  echo ''; \\\n\t\t\t  echo '-include $$(top_srcdir)/git.mk'; \\\n\t\t\t} > $$x.tmp || failed=1; \\\n\t\t\tif test x$$failed = x; then \\\n\t\t\t\tmv $$x.tmp $$x || failed=1; \\\n\t\t\tfi; \\\n\t\t\tif test x$$failed = x; then : else \\\n\t\t\t\techo \"Failed updating $$x\"; >&2 \\\n\t\t\t\tany_failed=1; \\\n\t\t\tfi; \\\n\tfi; done; test -z \"$$any_failed\"\n\ngit-mk-update:\n\twget $(GIT_MK_URL) -O $(top_srcdir)/git.mk\n\n.PHONY: git-all git-mk-install git-mk-update\n\n\n\n###############################################################################\n# Actual .gitignore generation:\n###############################################################################\n\n$(srcdir)/.gitignore: Makefile.am $(top_srcdir)/git.mk\n\t@echo \"git.mk: Generating $@\"\n\t@{ \\\n\t\tif test \"x$(DOC_MODULE)\" = x -o \"x$(DOC_MAIN_SGML_FILE)\" = x; then :; else \\\n\t\t\tfor x in \\\n\t\t\t\t$(DOC_MODULE)-decl-list.txt \\\n\t\t\t\t$(DOC_MODULE)-decl.txt \\\n\t\t\t\ttmpl/$(DOC_MODULE)-unused.sgml \\\n\t\t\t\t\"tmpl/*.bak\" \\\n\t\t\t\txml html \\\n\t\t\t; do echo \"/$$x\"; done; \\\n\t\t\tFLAVOR=$$(cd $(top_srcdir); $(AUTOCONF) --trace 'GTK_DOC_CHECK:$$2' ./configure.ac); \\\n\t\t\tcase $$FLAVOR in *no-tmpl*) echo /tmpl;; esac; \\\n\t\tfi; \\\n\t\tif test \"x$(DOC_MODULE)$(DOC_ID)\" = x -o \"x$(DOC_LINGUAS)\" = x; then :; else \\\n\t\t\tfor lc in $(DOC_LINGUAS); do \\\n\t\t\t\tfor x in \\\n\t\t\t\t\t$(if $(DOC_MODULE),$(DOC_MODULE).xml) \\\n\t\t\t\t\t$(DOC_PAGES) \\\n\t\t\t\t\t$(DOC_INCLUDES) \\\n\t\t\t\t; do echo \"/$$lc/$$x\"; done; \\\n\t\t\tdone; \\\n\t\t\tfor x in \\\n\t\t\t\t$(_DOC_OMF_ALL) \\\n\t\t\t\t$(_DOC_DSK_ALL) \\\n\t\t\t\t$(_DOC_HTML_ALL) \\\n\t\t\t\t$(_DOC_MOFILES) \\\n\t\t\t\t$(DOC_H_FILE) \\\n\t\t\t\t\"*/.xml2po.mo\" \\\n\t\t\t\t\"*/*.omf.out\" \\\n\t\t\t; do echo /$$x; done; \\\n\t\tfi; \\\n\t\tif test \"x$(HELP_ID)\" = x -o \"x$(HELP_LINGUAS)\" = x; then :; else \\\n\t\t\tfor lc in $(HELP_LINGUAS); do \\\n\t\t\t\tfor x in \\\n\t\t\t\t\t$(HELP_FILES) \\\n\t\t\t\t\t\"$$lc.stamp\" \\\n\t\t\t\t\t\"$$lc.mo\" \\\n\t\t\t\t; do echo \"/$$lc/$$x\"; done; \\\n\t\t\tdone; \\\n\t\tfi; \\\n\t\tif test \"x$(gsettings_SCHEMAS)\" = x; then :; else \\\n\t\t\tfor x in \\\n\t\t\t\t$(gsettings_SCHEMAS:.xml=.valid) \\\n\t\t\t\t$(gsettings__enum_file) \\\n\t\t\t; do echo \"/$$x\"; done; \\\n\t\tfi; \\\n\t\tif test \"x$(appdata_XML)\" = x; then :; else \\\n\t\t\tfor x in \\\n\t\t\t\t$(appdata_XML:.xml=.valid) \\\n\t\t\t; do echo \"/$$x\"; done; \\\n\t\tfi; \\\n\t\tif test \"x$(appstream_XML)\" = x; then :; else \\\n\t\t\tfor x in \\\n\t\t\t\t$(appstream_XML:.xml=.valid) \\\n\t\t\t; do echo \"/$$x\"; done; \\\n\t\tfi; \\\n\t\tif test -f $(srcdir)/po/Makefile.in.in; then \\\n\t\t\tfor x in \\\n\t\t\t\tpo/Makefile.in.in \\\n\t\t\t\tpo/Makefile.in.in~ \\\n\t\t\t\tpo/Makefile.in \\\n\t\t\t\tpo/Makefile \\\n\t\t\t\tpo/Makevars.template \\\n\t\t\t\tpo/POTFILES \\\n\t\t\t\tpo/Rules-quot \\\n\t\t\t\tpo/stamp-it \\\n\t\t\t\tpo/.intltool-merge-cache \\\n\t\t\t\t\"po/*.gmo\" \\\n\t\t\t\t\"po/*.header\" \\\n\t\t\t\t\"po/*.mo\" \\\n\t\t\t\t\"po/*.sed\" \\\n\t\t\t\t\"po/*.sin\" \\\n\t\t\t\tpo/$(GETTEXT_PACKAGE).pot \\\n\t\t\t\tintltool-extract.in \\\n\t\t\t\tintltool-merge.in \\\n\t\t\t\tintltool-update.in \\\n\t\t\t; do echo \"/$$x\"; done; \\\n\t\tfi; \\\n\t\tif test -f $(srcdir)/configure; then \\\n\t\t\tfor x in \\\n\t\t\t\tautom4te.cache \\\n\t\t\t\tconfigure \\\n\t\t\t\tconfig.h \\\n\t\t\t\tstamp-h1 \\\n\t\t\t\tlibtool \\\n\t\t\t\tconfig.lt \\\n\t\t\t; do echo \"/$$x\"; done; \\\n\t\tfi; \\\n\t\tif test \"x$(DEJATOOL)\" = x; then :; else \\\n\t\t\tfor x in \\\n\t\t\t\t$(DEJATOOL) \\\n\t\t\t; do echo \"/$$x.sum\"; echo \"/$$x.log\"; done; \\\n\t\t\techo /site.exp; \\\n\t\tfi; \\\n\t\tif test \"x$(am__dirstamp)\" = x; then :; else \\\n\t\t\techo \"$(am__dirstamp)\"; \\\n\t\tfi; \\\n\t\tif test \"x$(LTCOMPILE)\" = x -a \"x$(LTCXXCOMPILE)\" = x -a \"x$(GTKDOC_RUN)\" = x; then :; else \\\n\t\t\tfor x in \\\n\t\t\t\t\"*.lo\" \\\n\t\t\t\t\".libs\" \"_libs\" \\\n\t\t\t; do echo \"$$x\"; done; \\\n\t\tfi; \\\n\t\tfor x in \\\n\t\t\t.gitignore \\\n\t\t\t$(GITIGNOREFILES) \\\n\t\t\t$(CLEANFILES) \\\n\t\t\t$(PROGRAMS) $(check_PROGRAMS) $(EXTRA_PROGRAMS) \\\n\t\t\t$(LIBRARIES) $(check_LIBRARIES) $(EXTRA_LIBRARIES) \\\n\t\t\t$(LTLIBRARIES) $(check_LTLIBRARIES) $(EXTRA_LTLIBRARIES) \\\n\t\t\tso_locations \\\n\t\t\t$(MOSTLYCLEANFILES) \\\n\t\t\t$(TEST_LOGS) \\\n\t\t\t$(TEST_LOGS:.log=.trs) \\\n\t\t\t$(TEST_SUITE_LOG) \\\n\t\t\t\"*.gcda\" \\\n\t\t\t\"*.gcno\" \\\n\t\t\t$(DISTCLEANFILES) \\\n\t\t\t$(am__CONFIG_DISTCLEAN_FILES) \\\n\t\t\t$(CONFIG_CLEAN_FILES) \\\n\t\t\tTAGS ID GTAGS GRTAGS GSYMS GPATH tags \\\n\t\t\t\"*.tab.c\" \\\n\t\t\t$(MAINTAINERCLEANFILES) \\\n\t\t\t$(BUILT_SOURCES) \\\n\t\t\t$(patsubst %.vala,%.c,$(filter %.vala,$(SOURCES))) \\\n\t\t\t$(filter %_vala.stamp,$(DIST_COMMON)) \\\n\t\t\t$(filter %.vapi,$(DIST_COMMON)) \\\n\t\t\t$(filter $(addprefix %,$(notdir $(patsubst %.vapi,%.h,$(filter %.vapi,$(DIST_COMMON))))),$(DIST_COMMON)) \\\n\t\t\tMakefile \\\n\t\t\tMakefile.in \\\n\t\t\t\"*.orig\" \\\n\t\t\t\"*.rej\" \\\n\t\t\t\"*.bak\" \\\n\t\t\t\"*~\" \\\n\t\t\t\".*.sw[nop]\" \\\n\t\t\t\".dirstamp\" \\\n\t\t; do echo \"/$$x\"; done; \\\n\t\tfor x in \\\n\t\t\t\"*.$(OBJEXT)\" \\\n\t\t\t$(DEPDIR) \\\n\t\t; do echo \"$$x\"; done; \\\n\t} | \\\n\tsed \"s@^/`echo \"$(srcdir)\" | sed 's/\\(.\\)/[\\1]/g'`/@/@\" | \\\n\tsed 's@/[.]/@/@g' | \\\n\tLC_ALL=C sort | uniq > $@.tmp && \\\n\tmv $@.tmp $@;\n\nall: $(srcdir)/.gitignore gitignore-recurse-maybe\ngitignore: $(srcdir)/.gitignore gitignore-recurse\n\ngitignore-recurse-maybe:\n\t@for subdir in $(DIST_SUBDIRS); do \\\n\t  case \" $(SUBDIRS) \" in \\\n\t    *\" $$subdir \"*) :;; \\\n\t    *) test \"$$subdir\" = . -o -e \"$$subdir/.git\" || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) gitignore || echo \"Skipping $$subdir\");; \\\n\t  esac; \\\n\tdone\ngitignore-recurse:\n\t@for subdir in $(DIST_SUBDIRS); do \\\n\t    test \"$$subdir\" = . -o -e \"$$subdir/.git\" || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) gitignore || echo \"Skipping $$subdir\"); \\\n\tdone\n\nmaintainer-clean: gitignore-clean\ngitignore-clean:\n\t-rm -f $(srcdir)/.gitignore\n\n.PHONY: gitignore-clean gitignore gitignore-recurse gitignore-recurse-maybe\n"
  },
  {
    "path": "po/LINGUAS",
    "content": "# nuntius translations\n# please keep this list sorted alphabetically\nde\nes\npl\nsk\n"
  },
  {
    "path": "po/POTFILES.in",
    "content": "# List of source files containing translatable strings.\n# Please keep this file sorted alphabetically.\ndata/org.holylobster.nuntius.appdata.xml.in\ndata/org.holylobster.nuntius.desktop.in\n[type: gettext/gsettings]data/org.holylobster.nuntius.gschema.xml.in\nsrc/application.vala\nsrc/appslist.vala\n[type: gettext/glade]src/resources/gtk/menus.ui\n[type: gettext/glade]src/resources/ui/appslistpanel.ui\n[type: gettext/glade]src/resources/ui/window.ui\nsrc/smsnotification.vala\n"
  },
  {
    "path": "po/POTFILES.skip",
    "content": "# List of source files that should *not* be translated.\n# Please keep this file sorted alphabetically.\nsrc/application.c\nsrc/appslist.c\nsrc/smsnotification.c\n"
  },
  {
    "path": "po/de.po",
    "content": "# SOME DESCRIPTIVE TITLE.\n# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER\n# This file is distributed under the same license as the PACKAGE package.\n# Raphael Guttenberger <raphaelguttenberger@gmail.com>, 2015.\n#\nmsgid \"\"\nmsgstr \"\"\n\"Project-Id-Version: nuntius-linux\\n\"\n\"Report-Msgid-Bugs-To: \\n\"\n\"POT-Creation-Date: 2016-07-15 17:00+0200\\n\"\n\"PO-Revision-Date: 2015-03-11 18:29+0100\\n\"\n\"Last-Translator: Raphael Guttenberger <raphaelguttenberger@gmail.com>\\n\"\n\"Language-Team: \\n\"\n\"Language: de\\n\"\n\"MIME-Version: 1.0\\n\"\n\"Content-Type: text/plain; charset=UTF-8\\n\"\n\"Content-Transfer-Encoding: 8bit\\n\"\n\"Plural-Forms: nplurals=2; plural=(n != 1);\\n\"\n\n#: ../data/org.holylobster.nuntius.appdata.xml.in.h:1\nmsgid \"\"\n\"Nuntius delivers notifications from your phone or tablet to your computer \"\n\"over Bluetooth.\"\nmsgstr \"\"\n\"Nuntius sendet Benachrichtigungen von deinem Handy oder Tablet direkt an \"\n\"deinen Computer über Bluetooth.\"\n\n#: ../data/org.holylobster.nuntius.appdata.xml.in.h:2\nmsgid \"\"\n\"To use Nuntius you will need to install a companion tool on your phone or \"\n\"tablet and pair it via Bluetooth.\"\nmsgstr \"\"\n\"Um Nuntius zu benutzen, musst du ein Hilfstool auf deinem Handy oder Tablet \"\n\"installieren und es über Bluetooth mit deinem PC verbinden.\"\n\n#: ../data/org.holylobster.nuntius.desktop.in.h:1\nmsgid \"\"\n\"Deliver notifications from your phone or tablet to your computer over \"\n\"Bluetooth\"\nmsgstr \"\"\n\"Sende Benachrichtigungen von deinem Handy oder Tablet an deinen PC über \"\n\"Bluetooth\"\n\n#: ../data/org.holylobster.nuntius.desktop.in.h:2\nmsgid \"notifications;\"\nmsgstr \"Benachrichtigungen;\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:1\nmsgid \"Window state\"\nmsgstr \"\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:2\nmsgid \"State of the window, e.g. maximized.\"\nmsgstr \"\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:3\nmsgid \"Window width and height\"\nmsgstr \"\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:4\nmsgid \"Width and height of the window.\"\nmsgstr \"\"\n\n#: ../src/application.vala:144\nmsgid \"Connect to a specific server\"\nmsgstr \"\"\n\n#: ../src/application.vala:297\nmsgid \"Certificate Fingerprint\"\nmsgstr \"\"\n\n#: ../src/application.vala:300\nmsgid \"_OK\"\nmsgstr \"\"\n\n#: ../src/application.vala:469 ../src/resources/ui/window.ui.h:1\nmsgid \"Nuntius\"\nmsgstr \"\"\n\n#: ../src/application.vala:472\nmsgid \"\"\n\"Deliver notifications from your phone or tablet to your computer over \"\n\"Bluetooth.\"\nmsgstr \"\"\n\"Sende Benachrichtigungen von deinem Handy oder Tablet an deinen PC über \"\n\"Bluetooth.\"\n\n#: ../src/application.vala:477\nmsgid \"translator-credits\"\nmsgstr \"Raphael Guttenberger <raphaelguttenberger@gmail.com>, 2015\"\n\n#: ../src/appslist.vala:75\nmsgid \"Blacklist this application\"\nmsgstr \"\"\n\n#. namespace Nuntius\n#. ex:set ts=4 et:\n#: ../src/resources/gtk/menus.ui.h:1\nmsgid \"Show _QR Code\"\nmsgstr \"\"\n\n#: ../src/resources/gtk/menus.ui.h:2\nmsgid \"_About\"\nmsgstr \"\"\n\n#: ../src/resources/ui/appslistpanel.ui.h:1\nmsgid \"Type to search\"\nmsgstr \"\"\n\n#: ../src/resources/ui/window.ui.h:2\nmsgid \"All Applications\"\nmsgstr \"\"\n\n#. FIXME: just a test message until we have UI to type the reply\n#: ../src/smsnotification.vala:63\nmsgid \"Reply\"\nmsgstr \"\"\n"
  },
  {
    "path": "po/es.po",
    "content": "# SOME DESCRIPTIVE TITLE.\n# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER\n# This file is distributed under the same license as the PACKAGE package.\n# Daniel Mustieles <daniel.mustieles@gmail.com>, 2015.\n#\nmsgid \"\"\nmsgstr \"\"\n\"Project-Id-Version: nuntius-linux\\n\"\n\"Report-Msgid-Bugs-To: \\n\"\n\"POT-Creation-Date: 2016-07-15 17:00+0200\\n\"\n\"PO-Revision-Date: 2015-03-12 11:41+0100\\n\"\n\"Last-Translator: Daniel Mustieles <daniel.mustieles@gmail.com>\\n\"\n\"Language-Team: Español; Castellano <gnome-es-list@gnome.org>\\n\"\n\"Language: es\\n\"\n\"MIME-Version: 1.0\\n\"\n\"Content-Type: text/plain; charset=UTF-8\\n\"\n\"Content-Transfer-Encoding: 8bit\\n\"\n\"Plural-Forms: nplurals=2; plural=(n != 1);\\n\"\n\n#: ../data/org.holylobster.nuntius.appdata.xml.in.h:1\nmsgid \"\"\n\"Nuntius delivers notifications from your phone or tablet to your computer \"\n\"over Bluetooth.\"\nmsgstr \"\"\n\"Nuntius envía notificaciones desde su teléfono o tableta a su equipo \"\n\"mediante Bluetooth.\"\n\n#: ../data/org.holylobster.nuntius.appdata.xml.in.h:2\nmsgid \"\"\n\"To use Nuntius you will need to install a companion tool on your phone or \"\n\"tablet and pair it via Bluetooth.\"\nmsgstr \"\"\n\"Para usar Nuntius deberá instalar una herramienta complementaria en su \"\n\"teléfono o tableta y emparejarlo mediante Bluetooth.\"\n\n#: ../data/org.holylobster.nuntius.desktop.in.h:1\nmsgid \"\"\n\"Deliver notifications from your phone or tablet to your computer over \"\n\"Bluetooth\"\nmsgstr \"\"\n\"Enviar notificaciones desde su teléfono o tableta a su equipo mediante \"\n\"Bluetooth\"\n\n#: ../data/org.holylobster.nuntius.desktop.in.h:2\nmsgid \"notifications;\"\nmsgstr \"notificaciones;\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:1\nmsgid \"Window state\"\nmsgstr \"\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:2\nmsgid \"State of the window, e.g. maximized.\"\nmsgstr \"\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:3\nmsgid \"Window width and height\"\nmsgstr \"\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:4\nmsgid \"Width and height of the window.\"\nmsgstr \"\"\n\n#: ../src/application.vala:144\nmsgid \"Connect to a specific server\"\nmsgstr \"\"\n\n#: ../src/application.vala:297\nmsgid \"Certificate Fingerprint\"\nmsgstr \"\"\n\n#: ../src/application.vala:300\nmsgid \"_OK\"\nmsgstr \"\"\n\n#: ../src/application.vala:469 ../src/resources/ui/window.ui.h:1\nmsgid \"Nuntius\"\nmsgstr \"\"\n\n#: ../src/application.vala:472\nmsgid \"\"\n\"Deliver notifications from your phone or tablet to your computer over \"\n\"Bluetooth.\"\nmsgstr \"\"\n\"Enviar notificaciones desde su teléfono o tableta a su equipo mediante \"\n\"Bluetooth.\"\n\n#: ../src/application.vala:477\nmsgid \"translator-credits\"\nmsgstr \"Daniel Mustieles <daniel.mustieles@gmail.com>, 2015\"\n\n#: ../src/appslist.vala:75\nmsgid \"Blacklist this application\"\nmsgstr \"\"\n\n#. namespace Nuntius\n#. ex:set ts=4 et:\n#: ../src/resources/gtk/menus.ui.h:1\nmsgid \"Show _QR Code\"\nmsgstr \"\"\n\n#: ../src/resources/gtk/menus.ui.h:2\nmsgid \"_About\"\nmsgstr \"\"\n\n#: ../src/resources/ui/appslistpanel.ui.h:1\nmsgid \"Type to search\"\nmsgstr \"\"\n\n#: ../src/resources/ui/window.ui.h:2\nmsgid \"All Applications\"\nmsgstr \"\"\n\n#. FIXME: just a test message until we have UI to type the reply\n#: ../src/smsnotification.vala:63\nmsgid \"Reply\"\nmsgstr \"\"\n"
  },
  {
    "path": "po/pl.po",
    "content": "# Polish translation for nuntius-linux.\n# Copyright © 2015-2016 the nuntius-linux authors.\n# This file is distributed under the same license as the nuntius-linux package.\n# Piotr Drąg <piotrdrag@gmail.com>, 2015-2016.\n# Aviary.pl <community-poland@mozilla.org>, 2015-2016.\n#\nmsgid \"\"\nmsgstr \"\"\n\"Project-Id-Version: nuntius-linux\\n\"\n\"Report-Msgid-Bugs-To: \\n\"\n\"POT-Creation-Date: 2016-08-29 18:54+0200\\n\"\n\"PO-Revision-Date: 2016-08-29 18:55+0200\\n\"\n\"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\\n\"\n\"Language-Team: Polish <community-poland@mozilla.org>\\n\"\n\"Language: pl\\n\"\n\"MIME-Version: 1.0\\n\"\n\"Content-Type: text/plain; charset=UTF-8\\n\"\n\"Content-Transfer-Encoding: 8bit\\n\"\n\"Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 \"\n\"|| n%100>=20) ? 1 : 2);\\n\"\n\n#: ../data/org.holylobster.nuntius.appdata.xml.in.h:1\nmsgid \"\"\n\"Nuntius delivers notifications from your phone or tablet to your computer \"\n\"over Bluetooth.\"\nmsgstr \"\"\n\"Nuntius wyświetla powiadomienia z telefonu lub tabletu na komputerze za \"\n\"pomocą Bluetooth.\"\n\n#: ../data/org.holylobster.nuntius.appdata.xml.in.h:2\nmsgid \"\"\n\"To use Nuntius you will need to install a companion tool on your phone or \"\n\"tablet and pair it via Bluetooth.\"\nmsgstr \"\"\n\"Aby użyć programu Nuntius, należy zainstalować uzupełniające narzędzie na \"\n\"telefonie lub tablecie i połączyć je z komputerem za pomocą Bluetooth.\"\n\n#: ../data/org.holylobster.nuntius.desktop.in.h:1\nmsgid \"\"\n\"Deliver notifications from your phone or tablet to your computer over \"\n\"Bluetooth\"\nmsgstr \"\"\n\"Wyświetlanie powiadomień z telefonu lub tabletu na komputerze za pomocą \"\n\"Bluetooth\"\n\n#: ../data/org.holylobster.nuntius.desktop.in.h:2\nmsgid \"notifications;\"\nmsgstr \"\"\n\"powiadomienia;powiadamianie;notyfikacje;wiadomości;komunikaty;telefon;tablet;\"\n\"smartfon;phablet;fablet;android;\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:1\nmsgid \"Window state\"\nmsgstr \"Stan okna\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:2\nmsgid \"State of the window, e.g. maximized.\"\nmsgstr \"Stan okna, tzn. czy jest zmaksymalizowane.\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:3\nmsgid \"Window width and height\"\nmsgstr \"Szerokość i wysokość okna\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:4\nmsgid \"Width and height of the window.\"\nmsgstr \"Szerokość i wysokość okna.\"\n\n#: ../src/application.vala:144\nmsgid \"Connect to a specific server\"\nmsgstr \"Łączy z podanym serwerem\"\n\n#: ../src/application.vala:297\nmsgid \"Certificate Fingerprint\"\nmsgstr \"Odcisk certyfikatu\"\n\n#: ../src/application.vala:300\nmsgid \"_OK\"\nmsgstr \"_OK\"\n\n#: ../src/application.vala:469 ../src/resources/ui/window.ui.h:1\nmsgid \"Nuntius\"\nmsgstr \"Nuntius\"\n\n#: ../src/application.vala:472\nmsgid \"\"\n\"Deliver notifications from your phone or tablet to your computer over \"\n\"Bluetooth.\"\nmsgstr \"\"\n\"Wyświetlanie powiadomień z telefonu lub tabletu na komputerze za pomocą \"\n\"Bluetooth.\"\n\n#: ../src/application.vala:477\nmsgid \"translator-credits\"\nmsgstr \"\"\n\"Piotr Drąg <piotrdrag@gmail.com>, 2015-2016\\n\"\n\"Aviary.pl <community-poland@mozilla.org>, 2015-2016\"\n\n#: ../src/appslist.vala:75\nmsgid \"Blacklist this application\"\nmsgstr \"Dodaj program do czarnej listy\"\n\n#. namespace Nuntius\n#. ex:set ts=4 et:\n#: ../src/resources/gtk/menus.ui.h:1\nmsgid \"Show _QR Code\"\nmsgstr \"Wyświetl kod _QR\"\n\n#: ../src/resources/gtk/menus.ui.h:2\nmsgid \"_About\"\nmsgstr \"_O programie\"\n\n#: ../src/resources/ui/appslistpanel.ui.h:1\nmsgid \"Type to search\"\nmsgstr \"Wyszukiwanie\"\n\n#: ../src/resources/ui/window.ui.h:2\nmsgid \"All Applications\"\nmsgstr \"Wszystkie programy\"\n\n#. FIXME: just a test message until we have UI to type the reply\n#: ../src/smsnotification.vala:63\nmsgid \"Reply\"\nmsgstr \"Odpowiedz\"\n"
  },
  {
    "path": "po/sk.po",
    "content": "# SOME DESCRIPTIVE TITLE.\n# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER\n# This file is distributed under the same license as the PACKAGE package.\n# Dušan Kazik <prescott66@gmail.com>, 2015.\n#\nmsgid \"\"\nmsgstr \"\"\n\"Project-Id-Version: nuntius-linux\\n\"\n\"Report-Msgid-Bugs-To: \\n\"\n\"POT-Creation-Date: 2016-07-15 17:00+0200\\n\"\n\"PO-Revision-Date: 2015-03-20 18:28+0100\\n\"\n\"Last-Translator: Dušan Kazik <prescott66@gmail.com>\\n\"\n\"Language-Team: \\n\"\n\"Language: sk\\n\"\n\"MIME-Version: 1.0\\n\"\n\"Content-Type: text/plain; charset=UTF-8\\n\"\n\"Content-Transfer-Encoding: 8bit\\n\"\n\"Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\\n\"\n\n#: ../data/org.holylobster.nuntius.appdata.xml.in.h:1\nmsgid \"\"\n\"Nuntius delivers notifications from your phone or tablet to your computer \"\n\"over Bluetooth.\"\nmsgstr \"\"\n\"Nuntius doručí oznámenia z vášho telefónu alebo tabletu do vášho počítača \"\n\"cez Bluetooth.\"\n\n#: ../data/org.holylobster.nuntius.appdata.xml.in.h:2\nmsgid \"\"\n\"To use Nuntius you will need to install a companion tool on your phone or \"\n\"tablet and pair it via Bluetooth.\"\nmsgstr \"\"\n\"Na používanie programu Nuntius budete musieť vo vašom telefóne alebo tablete \"\n\"nainštalovať spoločný nástroj a spárovať ho cez Bluetooth.\"\n\n#: ../data/org.holylobster.nuntius.desktop.in.h:1\nmsgid \"\"\n\"Deliver notifications from your phone or tablet to your computer over \"\n\"Bluetooth\"\nmsgstr \"\"\n\"Doručenie oznámení z vášho telefónu alebo tabletu do vášho počítača cez \"\n\"Bluetooth\"\n\n#: ../data/org.holylobster.nuntius.desktop.in.h:2\nmsgid \"notifications;\"\nmsgstr \"oznámenia;upozornenia;\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:1\nmsgid \"Window state\"\nmsgstr \"Stav okna\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:2\nmsgid \"State of the window, e.g. maximized.\"\nmsgstr \"Stav okna, napr. maximalizované.\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:3\nmsgid \"Window width and height\"\nmsgstr \"Šírka a výška okna\"\n\n#: ../data/org.holylobster.nuntius.gschema.xml.in.h:4\nmsgid \"Width and height of the window.\"\nmsgstr \"Šírka a výška okna.\"\n\n#: ../src/application.vala:144\nmsgid \"Connect to a specific server\"\nmsgstr \"\"\n\n#: ../src/application.vala:297\nmsgid \"Certificate Fingerprint\"\nmsgstr \"\"\n\n#: ../src/application.vala:300\nmsgid \"_OK\"\nmsgstr \"\"\n\n#: ../src/application.vala:469 ../src/resources/ui/window.ui.h:1\nmsgid \"Nuntius\"\nmsgstr \"Nuntius\"\n\n#: ../src/application.vala:472\nmsgid \"\"\n\"Deliver notifications from your phone or tablet to your computer over \"\n\"Bluetooth.\"\nmsgstr \"\"\n\"Doručenie oznámení z vášho telefónu alebo tabletu do vášho počítača cez \"\n\"Bluetooth.\"\n\n#: ../src/application.vala:477\nmsgid \"translator-credits\"\nmsgstr \"Dušan Kazik <prescott66@gmail.com>, 2015\"\n\n#: ../src/appslist.vala:75\n#, fuzzy\nmsgid \"Blacklist this application\"\nmsgstr \"Všetky aplikácie\"\n\n#. namespace Nuntius\n#. ex:set ts=4 et:\n#: ../src/resources/gtk/menus.ui.h:1\nmsgid \"Show _QR Code\"\nmsgstr \"\"\n\n#: ../src/resources/gtk/menus.ui.h:2\nmsgid \"_About\"\nmsgstr \"_O programe\"\n\n#: ../src/resources/ui/appslistpanel.ui.h:1\nmsgid \"Type to search\"\nmsgstr \"Text na vyhľadanie\"\n\n#: ../src/resources/ui/window.ui.h:2\nmsgid \"All Applications\"\nmsgstr \"Všetky aplikácie\"\n\n#. FIXME: just a test message until we have UI to type the reply\n#: ../src/smsnotification.vala:63\nmsgid \"Reply\"\nmsgstr \"\"\n"
  },
  {
    "path": "src/application.vala",
    "content": "/*\n * Copyright (C) 2015 - Holy Lobster\n *\n * Nuntius is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * Nuntius is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with Nuntius. If not, see <http://www.gnu.org/licenses/>.\n */\n\nnamespace Nuntius {\n\n[DBus (name = \"org.bluez.Device1\")]\npublic interface BluezDeviceBus : Object {\n    public abstract async void connect_profile(string UUID) throws DBusError, IOError;\n    public abstract void disconnect_profile(string UUID) throws DBusError, IOError;\n\n    public abstract string name { owned get; }\n    public abstract bool paired { owned get; }\n    public abstract string[] uuids { owned get; }\n}\n\n[DBus (name = \"org.bluez.ProfileManager1\")]\npublic interface BluezProfileManager : Object {\n    public abstract void register_profile(ObjectPath profile, string uuid, HashTable<string, Variant> options) throws IOError;\n\n    public abstract void unregister_profile(ObjectPath profile) throws IOError;\n}\n\npublic class Connections : Object {\n    private HashTable<string, Connection>? connections;\n\n    construct {\n        connections = new HashTable<string, Connection>(str_hash, str_equal);\n    }\n\n    public void add_connection(Connection connection) {\n        connections.insert(connection.server_name, connection);\n        connection.notify[\"connected\"].connect(() => {\n            if (!connection.connected) {\n                connections.remove(connection.server_name);\n                print(\"removed connection for device '%s'\\n\",\n                      connection.server_name);\n            }\n        });\n\n        connection.notification_posted.connect((notification) => {\n            var app = (Application) GLib.Application.get_default();\n            app.add_notification(notification);\n        });\n\n        connection.sms_received.connect((sms_notification) => {\n            var app = (Application) GLib.Application.get_default();\n            app.add_sms_notification(sms_notification);\n        });\n\n        connection.notification_removed.connect((id, package_name) => {\n            var app = (Application) GLib.Application.get_default();\n            app.mark_notification_read(id, package_name);\n        });\n    }\n\n    public void remove_connection(string server_name) {\n        var connection = connections.lookup(server_name);\n        if (connection != null) {\n            connections.remove(server_name);\n        }\n    }\n\n    public bool is_connected() {\n        return connections.size() > 0;\n    }\n\n    public bool get_connected(string server_name) {\n        return connections.get(server_name) != null;\n    }\n}\n\n[DBus (name = \"org.bluez.Profile1\")]\npublic class BluezProfile : Object {\n    private Connections connections;\n\n    public BluezProfile(Connections connections) {\n        this.connections = connections;\n    }\n\n    public void release() {\n        print(\"release method called\\n\");\n    }\n\n    public void new_connection(ObjectPath device, Socket socket, HashTable<string, Variant> fd_properties) {\n        print(\"new_connection method called for device: %s\\n\", device);\n        var connection = new Connection(device,\n                                        SocketConnection.factory_create_connection(socket));\n\n        connections.add_connection(connection);\n    }\n\n    public void request_disconnection(ObjectPath device) {\n        print(\"request_disconnection method called for devices: %s\\n\", device);\n\n        connections.remove_connection(device);\n    }\n}\n\nprivate enum TcpConnectionStatus {\n    DISCONNECTED,\n    CONNECTING,\n    CONNECTED\n}\n\npublic class Application : Gtk.Application {\n    private Cancellable? cancellable;\n    private Connections connections;\n    private DBusObjectManager manager;\n    private BluezProfileManager? profile_manager;\n    private BluezProfile? profile;\n    private uint connect_devices_id;\n    private bool first_activation;\n    private bool cert_created;\n    private Window window;\n    private string connect_host;\n    private TcpConnectionStatus tcp_status;\n    private TlsCertificate? cert;\n    private List<NotificationApp> _notification_apps;\n    private List<SmsNotification> sms_notifications;\n\n    private const GLib.ActionEntry[] app_entries = {\n        { \"about\", on_about_activate },\n        { \"show-qrcode\", on_show_qrcode_activate },\n        { \"open-notifications-view\", on_open_notifications_view_activate, \"(ss)\"},\n        { \"send-sms\", on_send_sms_activate, \"(ss)\"}\n    };\n\n    private const OptionEntry[] options = {\n        {\"connect\", '\\0', 0, OptionArg.STRING, null,\n         N_(\"Connect to a specific server\"), null},\n        {null}\n    };\n\n    public signal void notification_app_added(NotificationApp notification_app);\n\n    public List<NotificationApp> notification_apps {\n        get { return _notification_apps; }\n    }\n\n    public Application() {\n        Object(application_id: \"org.holylobster.nuntius\",\n               flags: ApplicationFlags.HANDLES_COMMAND_LINE);\n        add_main_option_entries(options);\n    }\n\n    construct {\n        cancellable = new Cancellable();\n        cert_created = false;\n        first_activation = true;\n        tcp_status = TcpConnectionStatus.DISCONNECTED;\n        _notification_apps = new List<NotificationApp>();\n    }\n\n    protected override void dispose() {\n        if (cancellable != null) {\n            cancellable.cancel();\n            cancellable = null;\n        }\n\n        if (connect_devices_id != 0) {\n            Source.remove(connect_devices_id);\n            connect_devices_id = 0;\n        }\n\n        base.dispose();\n    }\n\n    protected override void startup() {\n        base.startup();\n\n        // Since it works as a daemon keep a hold forever on the primary instance\n        hold();\n\n        add_action_entries(app_entries, this);\n\n        var css_provider = new Gtk.CssProvider();\n        try {\n            var file = File.new_for_uri(\"resource:///org/holylobster/nuntius/css/nuntius-style.css\");\n            css_provider.load_from_file(file);\n        } catch (Error e) {\n            warning(\"loading css: %s\", e.message);\n        }\n        Gtk.StyleContext.add_provider_for_screen(Gdk.Screen.get_default(),\n                                                 css_provider,\n                                                 Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);\n\n        connections = new Connections();\n        profile = new BluezProfile(connections);\n\n        var profile_path = new ObjectPath(get_dbus_object_path() + \"/Profile\");\n\n        try {\n            var conn = Bus.get_sync(BusType.SYSTEM);\n            conn.register_object(profile_path, profile);\n\n            profile_manager = Bus.get_proxy_sync(BusType.SYSTEM, \"org.bluez\", \"/org/bluez\");\n            print(\"obtained bluez profile manager\\n\");\n\n            var options = new HashTable<string, Variant>(str_hash, str_equal);\n            options.insert(\"Role\", new Variant.string(\"client\"));\n\n            profile_manager.register_profile(profile_path, \"00001101-0000-1000-8000-00805f9b34fb\", options);\n            print(\"profile registered\\n\");\n\n            manager = new DBusObjectManagerClient.for_bus_sync(BusType.SYSTEM, DBusObjectManagerClientFlags.NONE,\n                                                               \"org.bluez\", \"/\", null, null);\n            print(\"obtained bluez proxy\\n\");\n\n            handle_managed_objects.begin(true);\n\n            // check interfaces added dynamically\n            manager.interface_added.connect(interface_added);\n            manager.interface_removed.connect(interface_removed);\n        } catch (Error e) {\n            warning(\"%s\", e.message);\n        }\n\n        create_cert();\n    }\n\n    private void ensure_window() {\n        if (window == null) {\n            window = new Window(this);\n            window.destroy.connect(() => {\n                window = null;\n            });\n        }\n    }\n\n    private string? spawn_command(string[] args) {\n        try {\n            string[] spawn_args = args;\n            string[] spawn_env = Environ.get ();\n            string ls_stdout;\n            string ls_stderr;\n            int ls_status;\n\n            Process.spawn_sync (\".\",\n                                spawn_args,\n                                spawn_env,\n                                SpawnFlags.SEARCH_PATH,\n                                null,\n                                out ls_stdout,\n                                out ls_stderr,\n                                out ls_status);\n            return ls_stdout;\n\n        } catch (SpawnError e) {\n            stdout.printf (\"Error: %s\\n\", e.message);\n            return null;\n        }\n    }\n\n    private void create_cert() {\n        var path_to_conf = GLib.Path.build_filename(GLib.Environment.get_user_config_dir(), \"nuntius\");\n        var cert_path = GLib.Path.build_filename(path_to_conf, \"nuntius.pem\");\n        var key_path = GLib.Path.build_filename(path_to_conf, \"nuntius.key\");\n        var file = File.new_for_path(cert_path);\n        if (!file.query_exists()) {\n            var script = GLib.Path.build_filename(Config.TOOLSDIR, \"createcert.sh\");\n            string[] spawn_args = { script };\n            spawn_command(spawn_args);\n            cert_created = true;\n        }\n        try {\n            cert = new TlsCertificate.from_files(cert_path, key_path);\n        } catch (Error e) {\n            warning(\"Failed to load certificate: %s\", e.message);\n        }\n    }\n\n    private string get_fingerprint() {\n        string path_to_pem = GLib.Path.build_filename(GLib.Environment.get_user_config_dir(), \"nuntius/nuntius.pem\");\n        string[] spawn_args = {\"openssl\", \"x509\", \"-in\", path_to_pem, \"-fingerprint\", \"-sha1\"};\n        string result = spawn_command(spawn_args);\n        string[] splitted = result.split(\"=\");\n        splitted = splitted[1].split(\"\\n\");\n        string fingerprint = splitted[0];\n        return fingerprint;\n    }\n\n    private void show_qrcode() {\n        var dialog = new Gtk.Dialog.with_buttons(_(\"Certificate Fingerprint\"),\n                                                 window,\n                                                 Gtk.DialogFlags.MODAL | Gtk.DialogFlags.DESTROY_WITH_PARENT,\n                                                 _(\"_OK\"),\n                                                 Gtk.ResponseType.OK);\n        dialog.border_width = 30;\n        dialog.set_default_size(300, 300);\n\n        dialog.response.connect(i => {\n            window.destroy();\n        });\n\n        var qr = new Nuntius.QRImage();\n        qr.text = get_fingerprint() + \"-\" + GLib.Environment.get_host_name();\n        qr.show();\n\n        dialog.get_content_area().pack_end(qr, true, true, 0);\n        dialog.show();\n    }\n\n    protected override void activate() {\n        // We want it to start as a daemon and not showing the window from\n        // the beginning\n        if (!first_activation) {\n            ensure_window();\n            window.present();\n            if (cert_created) {\n                show_qrcode();\n            }\n        }\n\n        first_activation = false;\n\n        if (tcp_status == TcpConnectionStatus.DISCONNECTED && connect_host != null && cert != null) {\n            var host = connect_host;\n            var client = new SocketClient();\n\n            tcp_status = TcpConnectionStatus.CONNECTING;\n\n            client.tls = true;\n            client.event.connect(on_socket_client_event);\n            client.connect_to_host_async.begin(connect_host, 12233, cancellable, (obj, res) => {\n                try {\n                    var connection = client.connect_to_host_async.end(res);\n                    tcp_status = TcpConnectionStatus.CONNECTED;\n                    connections.add_connection(new Connection(host, connection));\n                } catch (Error e) {\n                    tcp_status = TcpConnectionStatus.DISCONNECTED;\n                    warning(\"Could not connect to server: %s\", connect_host);\n                }\n            });\n        }\n\n        base.activate();\n    }\n\n    private void on_socket_client_event(SocketClientEvent event, SocketConnectable? connectable, IOStream? ios) {\n        if (event == SocketClientEvent.TLS_HANDSHAKING) {\n            var tls = (TlsConnection) ios;\n            tls.accept_certificate.connect((cert, err) => {\n                return true;\n            });\n            tls.set_certificate(cert);\n        }\n    }\n\n    protected override int command_line(ApplicationCommandLine cl) {\n        var dict = cl.get_options_dict();\n\n        dict.lookup(\"connect\", \"s\", out connect_host);\n        activate();\n\n        return 0;\n    }\n\n    private async void connect_interface(DBusObject object, DBusInterface iface, bool dump) {\n        if (!(iface is DBusProxy)) {\n            return;\n        }\n\n        var name = (iface as DBusProxy).get_interface_name();\n        var path = new ObjectPath(object.get_object_path());\n\n        if (dump) {\n            if (!name.has_prefix(\"org.freedesktop.DBus\")) {\n                print(\"added: [%s]\\n\", path);\n                print(\"  %s\\n\", name);\n            }\n        }\n\n        // try to get the device\n        if (name == \"org.bluez.Device1\" && !connections.get_connected(path)) {\n            try {\n                BluezDeviceBus device = Bus.get_proxy_sync(BusType.SYSTEM, \"org.bluez\", path);\n\n                if (device.paired) {\n                    print(\"connect device: %s\\n\", device.name);\n                    try {\n                        yield device.connect_profile(\"00001101-0000-1000-8000-00805f9b34fb\");\n                    } catch (Error e) {\n                        warning(\"Error connecting to device '%s': %s\", device.name, e.message);\n                    }\n                }\n            } catch (Error e) {\n                warning(\"%s\", e.message);\n            }\n        }\n    }\n\n    private void interface_added(DBusObjectManager manager, DBusObject object, DBusInterface iface) {\n        connect_interface.begin(object, iface, true);\n    }\n\n    private void interface_removed(DBusObjectManager manager, DBusObject object, DBusInterface iface) {\n        print(\"removed: [%s]\\n\", object.get_object_path());\n        print(\"  %s\\n\", iface.get_info().name);\n    }\n\n    private async void handle_managed_objects(bool dump) {\n        var objects = manager.get_objects();\n\n        foreach (DBusObject o in objects) {\n            foreach (DBusInterface iface in o.get_interfaces()) {\n                yield connect_interface(o, iface, dump);\n            }\n        }\n\n        if (!connections.is_connected()) {\n            // try to connect to the paired device every few seconds\n            connect_devices_id = Timeout.add_seconds(5, on_try_to_connect_devices);\n        }\n    }\n\n    private bool on_try_to_connect_devices() {\n        connect_devices_id = 0;\n        handle_managed_objects.begin(false);\n\n        return false;\n    }\n\n    public void on_open_notifications_view_activate(GLib.SimpleAction action, GLib.Variant? parameter) {\n        string id, package_name;\n        parameter.get(\"(ss)\", out id, out package_name);\n\n        Notification? notification = null;\n        notification = get_notification(id, package_name);\n        if (notification == null) {\n            return;\n        }\n\n        /* FIXME: just temporary until we add actions to the main UI */\n        if (notification.actions != null) {\n            var view = new TestView(notification);\n            view.show_all();\n            return;\n        }\n\n        /* FIXME for now just raise the main window */\n        activate();\n    }\n\n    private void on_about_activate() {\n        const string copyright = \"Copyright \\xc2\\xa9 2015 Holy Lobster Team\";\n\n        const string authors[] = {\n            \"Andrea Curtoni <andrea.curtoni@gmail.com>\",\n            \"Ignacio Casal Quinteiro <icq@gnome.org>\",\n            \"Paolo Borelli <pborelli@gnome.org>\",\n            null\n        };\n\n        Gtk.show_about_dialog(window,\n                              \"program-name\", _(\"Nuntius\"),\n                              \"logo-icon-name\", \"nuntius\",\n                              \"version\", Config.VERSION,\n                              \"comments\", _(\"Deliver notifications from your phone or tablet to your computer over Bluetooth.\"),\n                              \"copyright\", copyright,\n                              \"authors\", authors,\n                              \"license-type\", Gtk.License.GPL_2_0,\n                              \"wrap-license\", false,\n                              \"translator-credits\", _(\"translator-credits\"),\n                              null);\n    }\n\n    private void on_show_qrcode_activate() {\n        show_qrcode();\n    }\n\n    public Notification? get_notification(string id, string package_name) {\n        foreach (var napp in notification_apps) {\n            if (napp.id == package_name) {\n                var notification = napp.get_notification(id);\n                if (notification != null) {\n                    return notification;\n                }\n            }\n        }\n        return null;\n    }\n\n    public void add_notification(Notification notification) {\n        bool found = false;\n\n        foreach (var napp in _notification_apps) {\n            if (napp.id == notification.package_name) {\n                napp.add_notification(notification);\n                found = true;\n                break;\n            }\n        }\n\n        if (!found) {\n            var napp = new NotificationApp(notification.package_name, notification.connection);\n            napp.add_notification(notification);\n            _notification_apps.prepend(napp);\n\n            notification_app_added(napp);\n        }\n\n        send_notification(notification.id,\n                          notification.to_gnotification());\n    }\n\n    public void mark_notification_read(string id, string package_name) {\n        Notification? notification = null;\n\n        notification = get_notification(id, package_name);\n\n        if (notification != null) {\n            withdraw_notification(notification.id);\n            notification.read = true;\n        }\n    }\n\n    public void blacklist_application(string package_name) {\n        foreach (var napp in notification_apps) {\n            if (napp.id == package_name) {\n                napp.blacklist();\n            }\n        }\n    }\n\n    public SmsNotification? get_sms_notification(string id) {\n        foreach (var sms_notification in sms_notifications) {\n            if (sms_notification.id == id) {\n                return sms_notification;\n            }\n        }\n        return null;\n    }\n\n    public void add_sms_notification(SmsNotification sms_notification) {\n        sms_notifications.prepend(sms_notification);\n        send_notification(sms_notification.id, sms_notification.to_gnotification());\n    }\n\n    public void on_send_sms_activate(GLib.SimpleAction action, GLib.Variant? parameter) {\n        string id, text;\n        parameter.get(\"(ss)\", out id, out text);\n\n        if (id != null && text != null) {\n            var sms_notification = get_sms_notification(id);\n\n            if (sms_notification != null) {\n                sms_notification.send_sms_message(text);\n            }\n        }\n    }\n}\n\n} // namespace Nuntius\n\n/* ex:set ts=4 et: */\n"
  },
  {
    "path": "src/appslist.vala",
    "content": "/*\n * Copyright (C) 2015 - Holy Lobster\n *\n * Nuntius is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * Nuntius is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with Nuntius. If not, see <http://www.gnu.org/licenses/>.\n */\n\nnamespace Nuntius {\n\npublic class AppsList : Gtk.ListBox {\n    [GtkTemplate (ui = \"/org/holylobster/nuntius/ui/approw.ui\")]\n    public class AppRow : Gtk.ListBoxRow {\n        [GtkChild]\n        private Gtk.Image image;\n        [GtkChild]\n        private Gtk.Label label;\n        [GtkChild]\n        private NotificationCounter notification_counter;\n        private Gtk.Menu menu;\n\n        private NotificationApp _notification_app;\n\n        public NotificationApp notification_app {\n            get { return _notification_app; }\n            set construct { _notification_app = value; }\n        }\n\n        public AppRow(NotificationApp notification_app) {\n            Object(notification_app: notification_app);\n\n            image.set_from_gicon(notification_app.icon, Gtk.IconSize.BUTTON);\n            notification_app.bind_property(\"unread-notifications\",\n                                           notification_counter,\n                                           \"counter\",\n                                           BindingFlags.SYNC_CREATE);\n\n            if (notification_app.unread_notifications > 0) {\n                notification_counter.show();\n                label.set_markup(\"<b>\" + notification_app.app_name + \"</b>\");\n            } else {\n                label.set_label(notification_app.app_name);\n            }\n\n            notification_app.notify[\"app-name\"].connect(() => {\n                image.set_from_gicon(notification_app.icon, Gtk.IconSize.BUTTON);\n            });\n\n            notification_app.notify[\"icon\"].connect(() => {\n                label.set_label(notification_app.app_name);\n            });\n\n            notification_app.notify[\"unread-notifications\"].connect(() => {\n                notification_counter.set_visible(notification_app.unread_notifications > 0);\n\n                if (notification_app.unread_notifications > 0) {\n                    label.set_markup(\"<b>\" + notification_app.app_name + \"</b>\");\n                } else {\n                    label.set_label(notification_app.app_name);\n                }\n            });\n        }\n\n        public void show_popup_menu(Gdk.EventButton event) {\n            menu = new Gtk.Menu();\n            var item = new Gtk.MenuItem.with_label (_(\"Blacklist this application\"));\n            item.activate.connect(() => {\n                notification_app.blacklist();\n            });\n            menu.append(item);\n            menu.show_all();\n            menu.popup(null, null, null, event.button, event.get_time());\n        }\n    }\n\n    private string? filter_text;\n\n    public signal void selection_changed(NotificationApp? notification_app);\n\n    construct {\n        set_header_func(update_header);\n        set_filter_func(filter);\n\n        /* FIXME: get the napps as a property to not depend on the app? */\n        var app = GLib.Application.get_default() as Application;\n\n        foreach (var napp in app.notification_apps) {\n            var row = new AppRow(napp);\n            add(row);\n        }\n\n        app.notification_app_added.connect((napp) => {\n            var row = new AppRow(napp);\n            add(row);\n        });\n\n        button_press_event.connect((event) => {\n            if (event.type == Gdk.EventType.BUTTON_PRESS &&\n                event.button == Gdk.BUTTON_SECONDARY) {\n                print(\"button press right click\\n\");\n                unselect_all();\n\n                var row = get_row_at_y((int) event.y) as AppRow;\n                if (row != null) {\n                    select_row(get_row_at_y((int) event.y));\n                    row.show_popup_menu(event);\n                }\n\n                return true;\n            }\n\n            return false;\n        });\n    }\n\n    private void update_header(Gtk.ListBoxRow row, Gtk.ListBoxRow? before) {\n        row.set_header(before != null ? new Gtk.Separator(Gtk.Orientation.HORIZONTAL) : null);\n    }\n\n    private bool filter(Gtk.ListBoxRow row) {\n        return filter_text != null ? ((AppRow)row).notification_app.app_name.down().contains(filter_text) : true;\n    }\n\n    public override void row_selected(Gtk.ListBoxRow? row) {\n        var app_row = row as AppRow;\n        var notification_app = app_row != null ? app_row.notification_app : null;\n\n        selection_changed(notification_app);\n    }\n\n    public void set_filter_text(string text) {\n        filter_text = text.down();\n\n        invalidate_filter();\n    }\n}\n\n} // namespace Nuntius\n\n/* ex:set ts=4 et: */\n"
  },
  {
    "path": "src/appslistpanel.vala",
    "content": "/*\n * Copyright (C) 2015 - Holy Lobster\n *\n * Nuntius is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * Nuntius is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with Nuntius. If not, see <http://www.gnu.org/licenses/>.\n */\n\nnamespace Nuntius {\n\n[GtkTemplate (ui = \"/org/holylobster/nuntius/ui/appslistpanel.ui\")]\npublic class AppsListPanel : Gtk.Frame {\n    private uint filter_entry_changed_id;\n\n    [GtkChild]\n    private Gtk.ToolItem search_tool_item;\n\n    [GtkChild]\n    private Gtk.SearchEntry filter_entry;\n\n    [GtkChild]\n    private AppsList apps_list_view;\n\n    public void refilter() {\n        string str = filter_entry.get_text();\n\n        apps_list_view.set_filter_text(str);\n    }\n\n    private bool filter_entry_changed_timeout() {\n        filter_entry_changed_id = 0;\n        refilter();\n        return false;\n    }\n\n    [GtkCallback]\n    private void filter_entry_changed(Gtk.Editable editable) {\n        if (filter_entry_changed_id != 0) {\n            Source.remove(filter_entry_changed_id);\n        }\n\n        filter_entry_changed_id = Timeout.add(300, filter_entry_changed_timeout);\n    }\n\n    public signal void selection_changed(NotificationApp? notification_app);\n\n    construct {\n        search_tool_item.set_expand(true);\n\n        apps_list_view.selection_changed.connect((napp) => {\n            selection_changed(napp);\n        });\n    }\n}\n\n} // namespace Nuntius\n\n/* ex:set ts=4 et: */\n"
  },
  {
    "path": "src/config.vapi",
    "content": "[CCode (cprefix = \"\", lower_case_cprefix = \"\", cheader_filename = \"config.h\")]\nnamespace Config {\n    public const string VERSION;\n    public const string DATADIR;\n    public const string GETTEXT_PACKAGE;\n    public const string GNOMELOCALEDIR;\n    public const string TOOLSDIR;\n}\n\n"
  },
  {
    "path": "src/connection.vala",
    "content": "/*\n * Copyright (C) 2015 - Holy Lobster\n *\n * Nuntius is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * Nuntius is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with Nuntius. If not, see <http://www.gnu.org/licenses/>.\n */\n\nnamespace Nuntius {\n\npublic class Connection : Object {\n    private Cancellable cancellable;\n    private SocketConnection? _connection;\n    private DataInputStream? input;\n    private DataOutputStream? output;\n    private bool _connected;\n    private string _server_name;\n\n    public bool connected {\n        get { return _connected; }\n        set { _connected = value; }\n    }\n\n    public string server_name {\n        get { return _server_name; }\n        set construct { _server_name = value; }\n    }\n\n    public SocketConnection? connection {\n        get { return _connection; }\n        set construct { _connection = value; }\n    }\n\n    public signal void notification_posted(Notification notification);\n\n    public signal void sms_received(SmsNotification notification);\n\n    public signal void notification_removed(string id, string package_name);\n\n    public Connection(string server_name, SocketConnection connection) {\n        Object(connected: true, server_name: server_name, connection: connection);\n\n        input = new DataInputStream(_connection.get_input_stream());\n        input.set_newline_type(DataStreamNewlineType.CR_LF);\n        output = new DataOutputStream(_connection.get_output_stream());\n        read_message();\n    }\n\n    construct {\n        cancellable = new Cancellable();\n    }\n\n    protected override void dispose() {\n        if (cancellable != null) {\n            cancellable.cancel();\n            cancellable = null;\n        }\n\n        input = null;\n        connection = null;\n\n        base.dispose();\n    }\n\n    public void send_message(string msg) {\n        try {\n            output.put_string(msg + \"\\n\");\n        } catch (Error e) {\n            print(\"Couldn't send message to \" + _server_name);\n        }\n        print(msg);\n    }\n\n    void read_message() {\n        input.read_line_async.begin(Priority.DEFAULT, cancellable, (obj, res) => {\n            try {\n                string notification_json = input.read_line_async.end(res);\n\n                print(\"Got the json message: %s\\n\", notification_json);\n\n                var parser = new Json.Parser();\n                try {\n                    parser.load_from_data(notification_json, -1);\n                } catch (Error e) {\n                    warning(\"There was a problem parsing the notification data: %s\",\n                            e.message);\n                    read_message();\n                    return;\n                }\n\n                var event = parser.get_root().get_object().get_string_member(\"event\");\n                var eventItems = parser.get_root().get_object().get_array_member(\"eventItems\").get_elements();\n\n                switch (event) {\n                case \"deviceConnected\":\n                    foreach (var i in eventItems) {\n                        var object = i.get_object();\n                        var name = object.get_string_member(\"name\");\n                        print(\"Device '%s' connected\\n\", name);\n                    }\n                    break;\n                case \"notificationPosted\":\n                    foreach (var i in eventItems) {\n                        Notification? notification = null;\n                        string? key = null;\n\n                        var object = i.get_object();\n                        var id = object.get_int_member(\"id\").to_string();\n                        var package_name = object.get_string_member(\"packageName\");\n                        var app_name = object.get_string_member(\"appName\");\n\n                        BytesIcon icon = null;\n                        if (object.has_member(\"icon\")) {\n                            icon = new BytesIcon(new Bytes(Base64.decode(object.get_string_member(\"icon\"))));\n                        }\n\n                        if (object.has_member(\"key\")) {\n                            key = object.get_string_member(\"key\");\n                        }\n\n                        var notification_object = object.get_object_member(\"notification\");\n                        if (notification_object.has_member(\"title\")) {\n                            var title = notification_object.get_string_member(\"title\");\n                            string? text = null;\n                            string? flags = null;\n                            string[]? actions_string = null;\n\n                            if (notification_object.has_member(\"flags\")) {\n                                flags = notification_object.get_string_member(\"flags\");\n                            }\n\n                            if (notification_object.has_member(\"text\")) {\n                                text = notification_object.get_string_member(\"text\");\n                            }\n\n                            if (notification_object.has_member(\"actions\")) {\n                                var actions = notification_object.get_array_member(\"actions\").get_elements();\n                                var number_of_actions = notification_object.get_array_member(\"actions\").get_length();\n                                actions_string = new string[number_of_actions];\n                                var count = 0;\n                                foreach (var action in actions) {\n                                    actions_string[count] = action.get_object().get_string_member(\"title\");\n                                    count++;\n                                }\n                            }\n                            notification = new Notification(this, id, package_name, app_name, title, flags, key, text, icon, actions_string);\n\n                            notification_posted(notification);\n                        }\n                    }\n                    break;\n                case \"notificationRemoved\":\n                    foreach (var i in eventItems) {\n                        var object = i.get_object();\n                        var id = object.get_int_member(\"id\").to_string();\n                        var package_name = object.get_string_member(\"packageName\");\n                        notification_removed(id, package_name);\n                    }\n                    break;\n                case \"listNotifications\":\n                    break;\n                case \"sms\":\n                    foreach (var i in eventItems) {\n                        var object = i.get_object();\n                        string? id = null;\n                        string? sender = null;\n                        string? sender_num = null;\n                        string? msg = null;\n                        BytesIcon? icon = null;\n\n                        if (object.has_member(\"id\")) {\n                            id = object.get_string_member(\"id\");\n                        }\n\n                        if (object.has_member(\"sender\")) {\n                            sender = object.get_string_member(\"sender\");\n                        }\n\n                        if (object.has_member(\"sender_num\")) {\n                            sender_num = object.get_string_member(\"sender_num\");\n                        }\n\n                        if (object.has_member(\"message\")) {\n                            msg = object.get_string_member(\"message\");\n                        }\n\n                        if (object.has_member(\"icon\")) {\n                            icon = new BytesIcon(new Bytes(Base64.decode(object.get_string_member(\"icon\"))));\n                        }\n                        SmsNotification notification = new SmsNotification(this, id, sender, sender_num, msg, icon);\n                        sms_received(notification);\n                    }\n                    break;\n                default:\n                    warning(\"Unknown event: %s\", event);\n                    break;\n                }\n                /* read the next message */\n                read_message();\n            } catch (IOError e) {\n                warning(\"There was a problem reading the notification: %s\",\n                        e.message);\n                connected = false;\n            }\n        });\n    }\n}\n\n} // namespace Nuntius\n\n/* ex:set ts=4 et: */\n"
  },
  {
    "path": "src/main.vala",
    "content": "/*\n * Copyright (C) 2015 - Holy Lobster\n *\n * Nuntius is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * Nuntius is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with Nuntius. If not, see <http://www.gnu.org/licenses/>.\n */\n\nApplication app = null;\n\nbool on_terminate_app() {\n    app.release();\n    return false;\n}\n\npublic static int main(string[] args) {\n    Intl.bindtextdomain(Config.GETTEXT_PACKAGE, Config.GNOMELOCALEDIR);\n    Intl.bind_textdomain_codeset(Config.GETTEXT_PACKAGE, \"UTF-8\");\n    Intl.textdomain(Config.GETTEXT_PACKAGE);\n\n    app = new Nuntius.Application();\n\n    Unix.signal_add(Posix.Signal.INT, on_terminate_app);\n    Unix.signal_add(Posix.Signal.HUP, on_terminate_app);\n    Unix.signal_add(Posix.Signal.TERM, on_terminate_app);\n\n    return app.run(args);\n}\n\n/* ex:set ts=4 et: */\n"
  },
  {
    "path": "src/notification.vala",
    "content": "/*\n * Copyright (C) 2015 - Holy Lobster\n *\n * Nuntius is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * Nuntius is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with Nuntius. If not, see <http://www.gnu.org/licenses/>.\n */\n\nnamespace Nuntius {\n\npublic class Notification : Object {\n    public string id { get; construct set; }\n    public string package_name { get; construct set; }\n    public string app_name { get; construct set; }\n    public string title { get; construct set; }\n    public string body { get; construct set; }\n    public string? flag { get; construct set; }\n    public string? key { get; construct set; }\n    public BytesIcon icon { get; construct set; }\n    public string[]? actions { get; construct set; }\n    public Connection connection { get; construct set; }\n\n    private bool _read = false;\n\n    [CCode (notify = false)]\n    public bool read {\n        get {\n            return _read;\n        }\n        set {\n            if (_read != value) {\n                _read = value;\n                notify_property(\"read\");\n            }\n        }\n    }\n\n    public Notification(Connection connection, string id, string package_name, string app_name, string title, string? flag, string? key, string? body, BytesIcon? icon, string[]? actions) {\n        Object(connection: connection, id: id, package_name: package_name, app_name: app_name, title: title, flag: flag, key: key, body: body, icon: icon, actions: actions);\n    }\n\n    public void send_dismiss_message() {\n        Json.Builder builder = new Json.Builder();\n        builder.begin_object();\n        builder.set_member_name(\"event\");\n        builder.add_string_value(\"dismiss\");\n        builder.set_member_name(\"notification\");\n        builder.begin_object();\n\n        if (key != null){\n            builder.set_member_name(\"key\");\n            builder.add_string_value(_key);\n        } else {\n            builder.set_member_name(\"packageName\");\n            builder.add_string_value(_package_name);\n            builder.set_member_name(\"flag\");\n            builder.add_string_value(_flag);\n            builder.set_member_name(\"id\");\n            builder.add_string_value(_id);\n        }\n        builder.end_object();\n        builder.end_object();\n\n        Json.Generator generator = new Json.Generator();\n        Json.Node root = builder.get_root();\n        generator.set_root(root);\n        string dismiss_message = generator.to_data(null);\n        connection.send_message(dismiss_message);\n    }\n\n    public void send_action_message(string s) {\n        Json.Builder builder = new Json.Builder();\n        builder.begin_object();\n        builder.set_member_name(\"event\");\n        builder.add_string_value(\"action\");\n        builder.set_member_name(\"action\");\n        builder.begin_object();\n\n        builder.set_member_name(\"key\");\n        builder.add_string_value(_key);\n        builder.set_member_name(\"actionName\");\n        builder.add_string_value(s);\n\n        builder.end_object();\n        builder.end_object();\n\n        Json.Generator generator = new Json.Generator();\n        Json.Node root = builder.get_root();\n        generator.set_root(root);\n        string action_message = generator.to_data(null);\n        connection.send_message(action_message);\n    }\n\n    public GLib.Notification to_gnotification() {\n        GLib.Notification notification = new GLib.Notification(title);\n\n        if (body != null) {\n            notification.set_body(body);\n        }\n\n        if (icon != null) {\n            notification.set_icon(icon);\n        }\n\n        var variant = new Variant(\"(ss)\", id, package_name);\n        notification.set_default_action_and_target_value(\"app.open-notifications-view\", variant);\n\n        return notification;\n    }\n}\n\n} // namespace Nuntius\n\n/* ex:set ts=4 et: */\n"
  },
  {
    "path": "src/notificationapp.vala",
    "content": "/*\n * Copyright (C) 2015 - Holy Lobster\n *\n * Nuntius is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * Nuntius is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with Nuntius. If not, see <http://www.gnu.org/licenses/>.\n */\n\nnamespace Nuntius {\n\npublic class NotificationApp : Object {\n    public string id { get; construct set; }\n    public Connection connection { get; construct set; }\n    private string _app_name;\n    private BytesIcon _icon;\n    private uint _unread_notifications;\n    private List<Notification> _notifications;\n\n    public string app_name {\n        get { return _app_name; }\n    }\n\n    public BytesIcon icon {\n        get { return _icon; }\n    }\n\n    public uint unread_notifications {\n        get { return _unread_notifications; }\n    }\n\n    public List<Notification> notifications {\n        get { return _notifications; }\n    }\n\n    public NotificationApp(string id, Connection connection) {\n        Object(id: id, connection: connection);\n    }\n\n    construct {\n        _notifications = new List<Notification>();\n    }\n\n    public void add_notification(Notification notification) {\n        _notifications.prepend(notification);\n\n        // Update the icon with the latest notification\n        if (_icon != notification.icon) {\n            _icon = notification.icon;\n            notify_property(\"icon\");\n        }\n\n        if (_app_name != notification.app_name) {\n            _app_name = notification.app_name;\n            notify_property(\"app-name\");\n        }\n\n        if (!notification.read) {\n            _unread_notifications++;\n            notify_property(\"unread-notifications\");\n        }\n\n        notification.notify[\"read\"].connect(() => {\n            if (notification.read) {\n                _unread_notifications--;\n            } else {\n                _unread_notifications++;\n            }\n\n            notify_property(\"unread-notifications\");\n        });\n    }\n\n    public Notification get_notification(string id) {\n        Notification? n = null;\n\n        foreach (var notif in _notifications) {\n            if (notif.id == id) {\n                n = notif;\n                break;\n            }\n        }\n\n        return n;\n    }\n\n    public void blacklist() {\n        Json.Builder builder = new Json.Builder();\n        builder.begin_object();\n        builder.set_member_name(\"event\");\n        builder.add_string_value(\"blacklist\");\n        builder.set_member_name(\"app\");\n        builder.begin_object();\n\n        builder.set_member_name(\"packageName\");\n        builder.add_string_value(id);\n\n        builder.end_object();\n        builder.end_object();\n\n        Json.Generator generator = new Json.Generator();\n        Json.Node root = builder.get_root();\n        generator.set_root(root);\n\n        string blacklist_message = generator.to_data(null);\n        connection.send_message(blacklist_message);\n    }\n}\n\n} // namespace Nuntius\n\n/* ex:set ts=4 et: */\n"
  },
  {
    "path": "src/notificationcounter.vala",
    "content": "/*\n * Copyright (C) 2015 - Holy Lobster\n *\n * Nuntius is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * Nuntius is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with Nuntius. If not, see <http://www.gnu.org/licenses/>.\n */\n\nnamespace Nuntius {\n\n[GtkTemplate (ui = \"/org/holylobster/nuntius/ui/notificationcounter.ui\")]\npublic class NotificationCounter : Gtk.Frame {\n    private uint _counter;\n\n    [GtkChild]\n    private Gtk.Label label_counter;\n\n    public uint counter {\n        get { return _counter; }\n        set {\n            _counter = value;\n            label_counter.set_label(_counter.to_string());\n        }\n    }\n}\n\n} // namespace Nuntius\n\n/* ex:set ts=4 et: */\n"
  },
  {
    "path": "src/notificationsview.vala",
    "content": "/*\n * Copyright (C) 2015 - Holy Lobster\n *\n * Nuntius is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * Nuntius is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with Nuntius. If not, see <http://www.gnu.org/licenses/>.\n */\n\nnamespace Nuntius {\n\npublic class NotificationsView : Gtk.TextView {\n    private Gtk.TextTag notification_tag;\n    private Gtk.TextTag title_tag;\n    private bool first_notification;\n\n    construct {\n        var buf = get_buffer();\n\n        notification_tag = buf.create_tag(\"notification\", null);\n        title_tag = buf.create_tag(\"title\",\n                                   \"weight\",\n                                   Pango.Weight.BOLD,\n                                   null);\n    }\n\n    protected override void draw_layer(Gtk.TextViewLayer layer, Cairo.Context cr) {\n        cr.save();\n\n        if (layer == Gtk.TextViewLayer.BELOW) {\n            if (get_buffer() == null) {\n                return;\n            }\n\n            var context = get_style_context();\n\n            context.save();\n            context.add_class(\"notification\");\n\n            Gdk.Rectangle visible_rect;\n            get_visible_rect(out visible_rect);\n\n            Gdk.Rectangle clip;\n            Gdk.cairo_get_clip_rectangle(cr, out clip);\n\n            int x1, y1, x2, y2;\n            x1 = clip.x;\n            y1 = clip.y;\n            x2 = x1 + clip.width;\n            y2 = y1 + clip.height;\n\n            window_to_buffer_coords(Gtk.TextWindowType.TEXT,\n                                    x1, y1,\n                                    out x1, out y1);\n\n            window_to_buffer_coords(Gtk.TextWindowType.TEXT,\n                                    x2, y2,\n                                    out x2, out y2);\n\n            Gtk.TextIter s, e;\n            get_iter_at_location(out s, x1, y1);\n            get_iter_at_location(out e, x2, y2);\n\n            while (true) {\n                Gtk.TextIter it = s;\n\n                if (s.has_tag(notification_tag)) {\n                    if (!it.forward_to_tag_toggle(notification_tag)) {\n                        break;\n                    }\n\n                    Gdk.Rectangle rect1;\n                    get_iter_location(s, out rect1);\n\n                    buffer_to_window_coords(Gtk.TextWindowType.TEXT,\n                                            rect1.x, rect1.y,\n                                            out x1, out y1);\n\n                    if (it.compare(e) > 0) {\n                        it = e;\n                    }\n\n                    Gdk.Rectangle rect2;\n                    get_iter_location(it, out rect2);\n                    buffer_to_window_coords(Gtk.TextWindowType.TEXT,\n                                            rect2.x + rect2.width, rect2.y + rect2.height,\n                                            out x2, out y2);\n\n                    int x = left_margin / 2;\n                    int y = int.max(y1 - rect1.height / 2, clip.y);\n                    int width = clip.width - left_margin / 2 - right_margin / 2;\n                    int height = int.min(y2 + rect2.height / 2 - y1 + rect1.height / 2, clip.height);\n\n                    context.render_background(cr, x, y, width, height);\n                }\n\n                if (!s.forward_to_tag_toggle(notification_tag)) {\n                    break;\n                }\n\n                if (s.compare(e) > 0) {\n                    break;\n                }\n            }\n\n            context.restore();\n        }\n\n        cr.restore();\n    }\n\n    public void reset() {\n        get_buffer().set_text(\"\");\n        first_notification = true;\n    }\n\n    public void add_notification(Notification notification) {\n        var buf = get_buffer();\n        var insert = buf.get_insert();\n        Gtk.TextIter it;\n        buf.get_iter_at_mark(out it, insert);\n\n        if (first_notification) {\n            buf.insert(ref it, \"\\n\\n\", -1);\n        }\n\n#if VALA_0_28\n        buf.insert_with_tags(ref it, notification.title, -1, notification_tag, title_tag, null);\n\n        if (notification.body != null) {\n            buf.insert_with_tags(ref it, \"\\n\\n\", -1, notification_tag, null);\n            buf.insert_with_tags(ref it, notification.body, -1, notification_tag, null);\n        }\n#else\n        buf.insert_with_tags(it, notification.title, -1, notification_tag, title_tag, null);\n\n        if (notification.body != null) {\n            buf.insert_with_tags(it, \"\\n\\n\", -1, notification_tag, null);\n            buf.insert_with_tags(it, notification.body, -1, notification_tag, null);\n        }\n#endif\n\n        buf.insert(ref it, \"\\n\\n\\n\", -1);\n\n        first_notification = false;\n    }\n}\n\n} // namespace Nuntius\n\n/* ex:set ts=4 et: */\n"
  },
  {
    "path": "src/qrencode.vapi",
    "content": "\n/*\n * Minimal VAPI file for LIBQRENCODE Barcode library.\n */\nnamespace Qrencode {\n\n    [CCode (cheader_filename = \"qrencode.h\", cname = \"QRcode\", unref_function = \"QRcode_free\")]\n    public class QRcode {\n        [CCode (cname = \"QRcode_encodeString\")]\n        public QRcode.encodeString(string digits, int version, EcLevel level, Mode hint, int casesensitive);\n\n        public int version;\n        public int width;\n        [CCode (array_length = false)]\n        public uint8[] data;\n    }\n\n    [CCode (cheader_filename = \"qrencode.h\", cname=\"QRencLevel\")]\n    public enum EcLevel {\n        [CCode (cname=\"QR_ECLEVEL_L\")]\n        L,\n        [CCode (cname=\"QR_ECLEVEL_M\")]\n        M,\n        [CCode (cname=\"QR_ECLEVEL_Q\")]\n        Q,\n        [CCode (cname=\"QR_ECLEVEL_H\")]\n        H\n    }\n\n    [CCode (cheader_filename = \"qrencode.h\", cname=\"QRencodeMode\")]\n    public enum Mode {\n        [CCode (cname=\"QR_MODE_NUL\")]\n        NUL,\n        [CCode (cname=\"QR_MODE_NUM\")]\n        NUM,\n        [CCode (cname=\"QR_MODE_AN\")]\n        AN,\n        [CCode (cname=\"QR_MODE_8\")]\n        B8,\n        [CCode (cname=\"QR_MODE_KANJI\")]\n        KANJI,\n        [CCode (cname=\"QR_MODE_STRUCTURE\")]\n        STRUCTURE\n    }\n}\n"
  },
  {
    "path": "src/qrimage.vala",
    "content": "/*\n * Copyright (C) 2015 - Holy Lobster\n *\n * Nuntius is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * Nuntius is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with Nuntius. If not, see <http://www.gnu.org/licenses/>.\n */\n\nnamespace Nuntius {\n\npublic class QRImage : Gtk.DrawingArea {\n    private string _text;\n    private Qrencode.QRcode? qrcode;\n    private const double MIN_SQUARE_SIZE = 1.0;\n\n    [CCode (notify = false)]\n    public string text {\n        get { return _text; }\n        set {\n            if (_text != value) {\n                _text = value;\n                qrcode = new Qrencode.QRcode.encodeString(_text, 0,\n                                                          Qrencode.EcLevel.M,\n                                                          Qrencode.Mode.B8, 1);\n                notify_property(\"text\");\n\n                queue_draw();\n            }\n        }\n    }\n\n    protected override bool draw(Cairo.Context cr) {\n        if (qrcode != null) {\n            uint width, height;\n\n            width = get_allocated_width();\n            height = get_allocated_height();\n\n            /* make it square */\n            if (height < width) {\n                width = height;\n            }\n\n            double square_size = width / qrcode.width;\n            if (square_size < MIN_SQUARE_SIZE) {\n                square_size = MIN_SQUARE_SIZE;\n            }\n\n            cr.save();\n\n            cr.set_source_rgb(0, 0, 0);\n\n            for (int iy = 0; iy < qrcode.width; iy++) {\n                for (int ix = 0; ix < qrcode.width; ix++) {\n                    /* Symbol data is represented as an array contains\n                     * width*width uchars. Each uchar represents a module\n                     * (dot). If the less significant bit of the uchar\n                     * is 1, the corresponding module is black. The other\n                     * bits are meaningless for us.\n                     */\n                    if ((qrcode.data[iy * qrcode.width + ix] & 1) != 0) {\n                        cr.rectangle(ix * square_size, iy * square_size, square_size, square_size);\n                        cr.fill();\n                    }\n                }\n            }\n\n            cr.restore();\n        }\n\n        return false;\n    }\n}\n\n} // namespace Nuntius\n\n/* ex:set ts=4 et: */\n"
  },
  {
    "path": "src/resources/css/nuntius-style.css",
    "content": ".nuntius-titlebar-left {\n    /* the horizontal padding confuses left_side_size_group, so we\n       add it as margin-left to the first button instead (in mainWindow.ui);\n       also set the vertical padding to 0 so the separator extends to the\n       bottom */\n    padding: 0 1px;\n}\n\n.nuntius-titlebar-left:dir(ltr),\n.nuntius-titlebar-right:dir(rtl) {\n    border-top-right-radius: 0;\n}\n\n.nuntius-titlebar-right:dir(ltr),\n.nuntius-titlebar-left:dir(rtl) {\n    border-top-left-radius: 0;\n}\n\n.nuntius-titlebar-separator {\n    border-image: linear-gradient(to bottom, @theme_bg_color, shade(@borders, 1.2));\n    border-image-width: 0 1px 0 0;\n    border-image-slice: 1;\n}\n\n.nuntius-titlebar-separator:backdrop {\n    border-image: none;\n    border-color: transparent;\n}\n\nNuntiusAppsListPanel.frame:dir(ltr) {\n  border-width: 0 1px 0 0;\n}\n\nNuntiusAppsListPanel.frame:dir(rtl) {\n  border-width: 0 0 0 1px;\n}\n\n.apps-list-view {\n  background-color: transparent;\n}\n\nNuntiusNotificationCounter {\n  border-style: none;\n  border-radius: 10px;\n  background-color: darker(@theme_selected_bg_color);\n  color: @theme_selected_fg_color;\n  padding: 1px 6px;\n}\n\n/* Primary toolbar with no line at top to avoid conflicts with frame border */\nNuntiusWindow .primary-toolbar.toolbar {\n  border-width: 0;\n  border-bottom-width: 1px;\n  border-style: solid;\n  border-color: @borders;\n}\n\nNuntiusNotificationsView .notification {\n  border-radius: 2px;\n  background-color: @theme_bg_color;\n}\n"
  },
  {
    "path": "src/resources/gtk/menus.ui",
    "content": "<?xml version=\"1.0\"?>\n<interface>\n  <!-- interface-requires gtk+ 3.0 -->\n  <menu id=\"app-menu\">\n    <section>\n      <item>\n        <attribute name=\"label\" translatable=\"yes\">Show _QR Code</attribute>\n        <attribute name=\"action\">app.show-qrcode</attribute>\n      </item>\n      <item>\n        <attribute name=\"label\" translatable=\"yes\">_About</attribute>\n        <attribute name=\"action\">app.about</attribute>\n      </item>\n    </section>\n  </menu>\n</interface>\n"
  },
  {
    "path": "src/resources/nuntius.gresource.xml",
    "content": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<gresources>\n  <gresource prefix=\"/org/holylobster/nuntius\">\n    <file preprocess=\"xml-stripblanks\">ui/window.ui</file>\n    <file preprocess=\"xml-stripblanks\">ui/appslistpanel.ui</file>\n    <file preprocess=\"xml-stripblanks\">ui/approw.ui</file>\n    <file preprocess=\"xml-stripblanks\">ui/notificationcounter.ui</file>\n    <file preprocess=\"xml-stripblanks\">gtk/menus.ui</file>\n    <file>css/nuntius-style.css</file>\n  </gresource>\n</gresources>\n"
  },
  {
    "path": "src/resources/ui/approw.ui",
    "content": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!-- Generated with glade 3.18.3 -->\n<interface>\n  <requires lib=\"gtk+\" version=\"3.12\"/>\n  <template class=\"NuntiusAppsListAppRow\" parent=\"GtkListBoxRow\">\n    <property name=\"visible\">True</property>\n    <property name=\"can_focus\">True</property>\n    <child>\n      <object class=\"GtkGrid\" id=\"grid1\">\n        <property name=\"visible\">True</property>\n        <property name=\"can_focus\">False</property>\n        <property name=\"margin\">6</property>\n        <property name=\"column_spacing\">10</property>\n        <child>\n          <object class=\"GtkImage\" id=\"image\">\n            <property name=\"visible\">True</property>\n            <property name=\"can_focus\">False</property>\n            <property name=\"halign\">center</property>\n            <property name=\"valign\">center</property>\n          </object>\n          <packing>\n            <property name=\"left_attach\">0</property>\n            <property name=\"top_attach\">0</property>\n          </packing>\n        </child>\n        <child>\n          <object class=\"GtkLabel\" id=\"label\">\n            <property name=\"visible\">True</property>\n            <property name=\"can_focus\">False</property>\n            <property name=\"halign\">start</property>\n            <property name=\"valign\">center</property>\n            <property name=\"hexpand\">true</property>\n            <property name=\"ellipsize\">end</property>\n          </object>\n          <packing>\n            <property name=\"left_attach\">1</property>\n            <property name=\"top_attach\">0</property>\n          </packing>\n        </child>\n        <child>\n          <object class=\"NuntiusNotificationCounter\" id=\"notification_counter\">\n            <property name=\"visible\">False</property>\n            <property name=\"can_focus\">False</property>\n            <property name=\"halign\">end</property>\n            <property name=\"valign\">center</property>\n          </object>\n          <packing>\n            <property name=\"left_attach\">2</property>\n            <property name=\"top_attach\">0</property>\n          </packing>\n        </child>\n      </object>\n    </child>\n  </template>\n</interface>\n"
  },
  {
    "path": "src/resources/ui/appslistpanel.ui",
    "content": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!-- Generated with glade 3.18.1 -->\n<interface>\n  <requires lib=\"gtk+\" version=\"3.14\"/>\n  <template class=\"NuntiusAppsListPanel\" parent=\"GtkFrame\">\n    <property name=\"visible\">True</property>\n    <property name=\"can_focus\">False</property>\n    <property name=\"label_xalign\">0</property>\n    <property name=\"shadow_type\">in</property>\n    <child>\n      <object class=\"GtkGrid\" id=\"grid1\">\n        <property name=\"visible\">True</property>\n        <property name=\"can_focus\">False</property>\n        <child>\n          <object class=\"GtkToolbar\" id=\"toolbar\">\n            <property name=\"visible\">True</property>\n            <property name=\"can_focus\">False</property>\n            <property name=\"hexpand\">True</property>\n            <child>\n              <object class=\"GtkToolItem\" id=\"search_tool_item\">\n                <property name=\"visible\">True</property>\n                <property name=\"can_focus\">False</property>\n                <child>\n                  <object class=\"GtkSearchEntry\" id=\"filter_entry\">\n                    <property name=\"visible\">True</property>\n                    <property name=\"can_focus\">True</property>\n                    <property name=\"width-chars\">30</property>\n                    <property name=\"placeholder_text\" translatable=\"yes\">Type to search</property>\n                    <signal name=\"changed\" handler=\"filter_entry_changed\" after=\"no\" swapped=\"no\"/>\n                  </object>\n                </child>\n              </object>\n              <packing>\n                <property name=\"expand\">False</property>\n                <property name=\"homogeneous\">True</property>\n              </packing>\n            </child>\n            <style>\n              <class name=\"primary-toolbar\"/>\n            </style>\n          </object>\n          <packing>\n            <property name=\"left_attach\">0</property>\n            <property name=\"top_attach\">0</property>\n          </packing>\n        </child>\n        <child>\n          <object class=\"GtkScrolledWindow\" id=\"scrolledwindow\">\n            <property name=\"visible\">True</property>\n            <property name=\"can_focus\">True</property>\n            <property name=\"hexpand\">True</property>\n            <property name=\"vexpand\">True</property>\n            <property name=\"hscrollbar_policy\">never</property>\n            <child>\n              <object class=\"NuntiusAppsList\" id=\"apps_list_view\">\n                <property name=\"visible\">True</property>\n                <property name=\"selection_mode\">browse</property>\n                <style>\n                  <class name=\"apps-list-view\"/>\n                </style>\n              </object>\n            </child>\n          </object>\n          <packing>\n            <property name=\"left_attach\">0</property>\n            <property name=\"top_attach\">1</property>\n          </packing>\n        </child>\n      </object>\n    </child>\n  </template>\n</interface>\n"
  },
  {
    "path": "src/resources/ui/notificationcounter.ui",
    "content": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!-- Generated with glade 3.18.1 -->\n<interface>\n  <template class=\"NuntiusNotificationCounter\" parent=\"GtkFrame\">\n    <property name=\"can_focus\">False</property>\n    <property name=\"shadow_type\">none</property>\n    <child>\n      <object class=\"GtkLabel\" id=\"label_counter\">\n        <property name=\"visible\">True</property>\n        <property name=\"can_focus\">False</property>\n        <property name=\"halign\">center</property>\n        <property name=\"valign\">center</property>\n        <property name=\"ellipsize\">end</property>\n      </object>\n    </child>\n  </template>\n</interface>\n"
  },
  {
    "path": "src/resources/ui/window.ui",
    "content": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!-- Generated with glade 3.18.1 -->\n<interface>\n  <requires lib=\"gtk+\" version=\"3.12\"/>\n  <template class=\"NuntiusWindow\" parent=\"GtkApplicationWindow\">\n    <property name=\"can_focus\">False</property>\n    <property name=\"default_width\">800</property>\n    <property name=\"default_height\">600</property>\n    <property name=\"title\" translatable=\"yes\">Nuntius</property>\n    <property name=\"icon_name\">nuntius</property>\n    <child type=\"titlebar\">\n      <object class=\"GtkBox\" id=\"box_titlebar\">\n        <property name=\"visible\">True</property>\n        <property name=\"can_focus\">False</property>\n        <child>\n          <object class=\"GtkHeaderBar\" id=\"titlebar_left\">\n            <property name=\"visible\">True</property>\n            <property name=\"can_focus\">False</property>\n            <property name=\"hexpand\">False</property>\n            <property name=\"title\" translatable=\"yes\">All Applications</property>\n            <child>\n              <object class=\"GtkLabel\" id=\"titlebar_separator\">\n                <property name=\"visible\">True</property>\n                <property name=\"can_focus\">False</property>\n                <style>\n                  <class name=\"nuntius-titlebar-separator\"/>\n                </style>\n              </object>\n              <packing>\n                <property name=\"pack_type\">end</property>\n              </packing>\n            </child>\n            <style>\n              <class name=\"nuntius-titlebar-left\"/>\n              <class name=\"titlebar\"/>\n            </style>\n          </object>\n          <packing>\n            <property name=\"expand\">False</property>\n            <property name=\"fill\">True</property>\n            <property name=\"position\">0</property>\n          </packing>\n        </child>\n        <child>\n          <object class=\"GtkHeaderBar\" id=\"titlebar_right\">\n            <property name=\"visible\">True</property>\n            <property name=\"can_focus\">False</property>\n            <property name=\"hexpand\">True</property>\n            <property name=\"show_close_button\">True</property>\n            <style>\n              <class name=\"nuntius-titlebar-right\"/>\n              <class name=\"titlebar\"/>\n            </style>\n          </object>\n          <packing>\n            <property name=\"expand\">False</property>\n            <property name=\"fill\">True</property>\n            <property name=\"position\">1</property>\n          </packing>\n        </child>\n      </object>\n    </child>\n    <child>\n      <object class=\"GtkGrid\" id=\"main_grid\">\n        <property name=\"visible\">True</property>\n        <property name=\"can_focus\">False</property>\n        <child>\n          <object class=\"GtkFrame\" id=\"sidebar_frame\">\n            <property name=\"visible\">True</property>\n            <property name=\"can_focus\">False</property>\n            <property name=\"hexpand\">False</property>\n            <property name=\"vexpand\">True</property>\n            <property name=\"label_xalign\">0</property>\n            <property name=\"shadow_type\">none</property>\n            <child>\n              <object class=\"NuntiusAppsListPanel\" id=\"apps_list_panel\">\n                <property name=\"visible\">True</property>\n              </object>\n            </child>\n          </object>\n        </child>\n        <child>\n          <object class=\"GtkScrolledWindow\" id=\"view_scrolled\">\n            <property name=\"visible\">True</property>\n            <property name=\"can_focus\">False</property>\n            <property name=\"hexpand\">True</property>\n            <property name=\"vexpand\">True</property>\n            <child>\n              <object class=\"NuntiusNotificationsView\" id=\"notifications_view\">\n                <property name=\"visible\">True</property>\n                <property name=\"editable\">False</property>\n                <property name=\"cursor_visible\">False</property>\n                <property name=\"wrap_mode\">word</property>\n                <property name=\"left_margin\">40</property>\n                <property name=\"right_margin\">40</property>\n              </object>\n            </child>\n          </object>\n        </child>\n      </object>\n    </child>\n  </template>\n  <object class=\"GtkSizeGroup\" id=\"left_side_size_group\">\n    <property name=\"mode\">horizontal</property>\n    <widgets>\n      <widget name=\"titlebar_left\"/>\n      <widget name=\"sidebar_frame\"/>\n    </widgets>\n  </object>\n</interface>\n"
  },
  {
    "path": "src/smsnotification.vala",
    "content": "/*\n * Copyright (C) 2015 - Holy Lobster\n *\n * Nuntius is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * Nuntius is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with Nuntius. If not, see <http://www.gnu.org/licenses/>.\n */\nnamespace Nuntius {\n\npublic class SmsNotification : Object {\n    public string id { get; construct set; }\n    public string sender { get; construct set; }\n    public string sender_num { get; construct set; }\n    public string message { get; construct set; }\n    public BytesIcon icon { get; construct set; }\n    public Connection connection { get; construct set; }\n\n    public SmsNotification(Connection connection, string id, string sender, string sender_num, string message, BytesIcon icon) {\n        Object(connection: connection, id: id, sender: sender, sender_num: sender_num, message: message, icon: icon);\n    }\n\n    public void send_sms_message(string message) {\n        Json.Builder builder = new Json.Builder();\n        builder.begin_object();\n        builder.set_member_name(\"event\");\n        builder.add_string_value(\"sms\");\n        builder.set_member_name(\"sms\");\n        builder.begin_object();\n\n        builder.set_member_name(\"senderNum\");\n        builder.add_string_value(_sender_num);\n\n        builder.set_member_name(\"msg\");\n        builder.add_string_value(message);\n\n        builder.end_object();\n        builder.end_object();\n\n        Json.Generator generator = new Json.Generator();\n        Json.Node root = builder.get_root();\n        generator.set_root(root);\n        string sms_message = generator.to_data(null);\n        connection.send_message(sms_message);\n    }\n\n    public GLib.Notification to_gnotification() {\n        GLib.Notification notification = new GLib.Notification(sender);\n\n        notification.set_body(message);\n        notification.set_icon(icon);\n\n        // FIXME: just a test message until we have UI to type the reply\n        var variant = new Variant(\"(ss)\", id, \"Sent by Nuntius\");\n        notification.add_button_with_target_value(_(\"Reply\"),\"app.send-sms\", variant);\n\n        return notification;\n    }\n}\n\n}\n"
  },
  {
    "path": "src/testview.vala",
    "content": "/*\n * Copyright (C) 2015 - Holy Lobster\n *\n * Nuntius is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * Nuntius is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with Nuntius. If not, see <http://www.gnu.org/licenses/>.\n */\n\nnamespace Nuntius {\n\n/* Just a temporary UI to send actions, this should go in the main UI */\npublic class TestView : Gtk.Window {\n\n    Notification notification;\n\n    public TestView(Notification notification) {\n        this.notification = notification;\n\n        // Sets the title of the Window:\n        this.title = notification.title;\n\n        // Center window at startup:\n        this.window_position = Gtk.WindowPosition.CENTER;\n\n        // Sets the default size of a window:\n        this.set_default_size(500,150);\n\n        // Whether the titlebar should be hidden during maximization.\n        this.hide_titlebar_when_maximized = false;\n\n        // Method called on pressing [X]\n        this.destroy.connect(() => {\n            stdout.printf(\"Bye!\\n\");\n        });\n\n        Gtk.Box vertical_box = new Gtk.Box(Gtk.Orientation.VERTICAL, 0);\n        vertical_box.set_margin_left(20);\n        vertical_box.set_margin_right(20);\n        this.add(vertical_box);\n\n        Gtk.Box notification_area = new Gtk.Box(Gtk.Orientation.HORIZONTAL, 10);\n        vertical_box.pack_start(notification_area);\n\n        Gtk.Image icon = new Gtk.Image();\n        icon.set_from_gicon(notification.icon, Gtk.IconSize.DIALOG);\n        notification_area.pack_start(icon);\n\n        var label = new Gtk.Label(notification.body);\n        notification_area.pack_start(label);\n\n        Gtk.Box button_area = new Gtk.Box(Gtk.Orientation.HORIZONTAL, 10);\n        vertical_box.pack_start(button_area, false, false, 10);\n        var dismiss_button = new Gtk.Button.with_label(\"Dismiss\");\n\n        dismiss_button.clicked.connect(() => {\n            notification.send_dismiss_message();\n        });\n\n        button_area.pack_start(dismiss_button);\n\n        if (notification.actions != null) {\n            var actions = notification.actions;\n            foreach(string s in actions) {\n                var action_button = new Gtk.Button.with_label(s);\n                button_area.pack_start(action_button);\n                action_button.clicked.connect(() => {\n                    notification.send_action_message(s);\n                });\n            }\n        }\n\n        var blacklist_button = new Gtk.Button.with_label(\"Blacklist this app\");\n\n        blacklist_button.clicked.connect(() => {\n            var app = (Application) GLib.Application.get_default();\n            app.blacklist_application(notification.package_name);\n        });\n\n        button_area.pack_start(blacklist_button);\n    }\n}\n\n}\n"
  },
  {
    "path": "src/window.vala",
    "content": "/*\n * Copyright (C) 2015 - Holy Lobster\n *\n * Nuntius is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * Nuntius is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with Nuntius. If not, see <http://www.gnu.org/licenses/>.\n */\n\nnamespace Nuntius {\n\n[GtkTemplate (ui = \"/org/holylobster/nuntius/ui/window.ui\")]\npublic class Window : Gtk.ApplicationWindow {\n    [GtkChild]\n    private AppsListPanel apps_list_panel;\n    [GtkChild]\n    private NotificationsView notifications_view;\n    [GtkChild]\n    private Gtk.HeaderBar titlebar_right;\n\n    private GLib.Settings settings;\n\n    public Window(Application app) {\n        Object(application: app);\n    }\n\n    construct {\n        settings = new Settings(\"org.holylobster.nuntius.state.window\");\n        settings.delay ();\n\n        destroy.connect(() => {\n            settings.apply();\n        });\n\n        // Setup window geometry saving\n        Gdk.WindowState window_state = (Gdk.WindowState)settings.get_int(\"state\");\n        if (Gdk.WindowState.MAXIMIZED in window_state) {\n            maximize();\n        }\n\n        int width, height;\n        settings.get (\"size\", \"(ii)\", out width, out height);\n        resize(width, height);\n\n        apps_list_panel.selection_changed.connect(on_selection_changed);\n    }\n\n    protected override bool configure_event(Gdk.EventConfigure event) {\n        if (get_realized() && !(Gdk.WindowState.MAXIMIZED in get_window ().get_state())) {\n            settings.set(\"size\", \"(ii)\", event.width, event.height);\n        }\n\n        return base.configure_event(event);\n    }\n\n    protected override bool window_state_event(Gdk.EventWindowState event) {\n        settings.set_int(\"state\", event.new_window_state);\n        return base.window_state_event(event);\n    }\n\n    protected override bool delete_event(Gdk.EventAny event) {\n        return base.hide_on_delete();\n    }\n\n    private void on_selection_changed(NotificationApp? notification_app) {\n        if (notification_app == null) {\n            titlebar_right.title = null;\n            return;\n        }\n\n        titlebar_right.title = notification_app.app_name;\n\n        notifications_view.reset();\n\n        foreach (var n in notification_app.notifications) {\n            notifications_view.add_notification(n);\n\n            if (!n.read) {\n                this.application.withdraw_notification(n.id);\n                n.read = true;\n            }\n        }\n    }\n}\n\n} // namespace Nuntius\n\n/* ex:set ts=4 et: */\n"
  },
  {
    "path": "tests/qrtest.vala",
    "content": "/*\n * Copyright (C) 2015 - Holy Lobster\n *\n * Nuntius is free software; you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation; either version 2 of the License, or\n * (at your option) any later version.\n *\n * Nuntius is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with Nuntius. If not, see <http://www.gnu.org/licenses/>.\n */\n\npublic static int main(string[] args) {\n    Gtk.init(ref args);\n\n    var window = new Gtk.Window();\n    window.title = \"QR Test\";\n    window.border_width = 10;\n    window.set_default_size(350, 70);\n    window.destroy.connect(Gtk.main_quit);\n\n    var qr = new Nuntius.QRImage();\n    qr.text = \"This is a test\";\n\n    window.add(qr);\n    window.show_all();\n\n    Gtk.main();\n\n    return 0;\n}\n\n/* ex:set ts=4 et: */\n"
  }
]