Merge lp:~vtuson/telegram-app/libqtelegram_bug1379417 into lp:telegram-app/trunk

Proposed by Victor Tuson Palau
Status: Merged
Merge reported by: Michał Karnicki
Merged at revision: not available
Proposed branch: lp:~vtuson/telegram-app/libqtelegram_bug1379417
Merge into: lp:telegram-app/trunk
Diff against target: 8811 lines (+8276/-0) (has conflicts)
85 files modified
.bzrignore (+20/-0)
CMakeLists.txt (+158/-0)
LICENSE (+674/-0)
README.md (+195/-0)
README.translations (+35/-0)
apparmor-push.json (+7/-0)
apparmor-telegram.json (+11/-0)
bootstrap.sh (+55/-0)
build.sh (+23/-0)
clean.sh (+8/-0)
click.sh (+52/-0)
components/CMakeLists.txt (+9/-0)
components/ContactImport.qml (+111/-0)
components/PageLoader.qml (+13/-0)
components/PictureImport.qml (+110/-0)
components/SentPhraseBubble.qml (+41/-0)
components/TelegramBubble.qml (+16/-0)
components/TelegramButton.qml (+47/-0)
components/TelegramColors.js (+21/-0)
components/TelegramContactsListItem.qml (+92/-0)
components/TelegramDelegate.qml (+196/-0)
components/TelegramDialogsListItem.qml (+216/-0)
components/TelegramHeader.qml (+79/-0)
components/TelegramLabel.qml (+10/-0)
components/TelegramPage.qml (+100/-0)
components/TelegramSection.qml (+29/-0)
components/TgButton.qml (+10/-0)
components/TgLabel.qml (+11/-0)
components/TgTextField.qml (+10/-0)
components/country_data.js (+6/-0)
components/iso_3166_2_countries.csv (+269/-0)
components/listitems/CMakeLists.txt (+7/-0)
components/listitems/DlgItem.qml (+15/-0)
components/listitems/DlgItemDesign.qml (+226/-0)
components/listitems/IconVisual.qml (+52/-0)
components/listitems/ImageWithFallback.qml (+46/-0)
components/listitems/LabelVisual.qml (+38/-0)
components/listitems/ProgressionVisual.qml (+52/-0)
countries.py (+52/-0)
debug.md (+110/-0)
images/conversation_incoming@27.sci (+5/-0)
images/conversation_outgoing@27.sci (+5/-0)
images/telegram.svg (+198/-0)
images/telegram_symbolic.svg (+192/-0)
js/avatar.js (+21/-0)
js/ba-linkify.js (+211/-0)
js/time.js (+44/-0)
manifest.json.in (+20/-0)
po/CMakeLists.txt (+29/-0)
po/ca.po (+403/-0)
po/com.ubuntu.telegram.pot (+400/-0)
po/es.po (+392/-0)
push.json (+4/-0)
push.py.in (+40/-0)
run.sh (+40/-0)
scripts/applog.sh (+16/-0)
scripts/inspect-db.sh (+11/-0)
scripts/pid.sh (+3/-0)
scripts/rm-config.sh (+3/-0)
scripts/rm-database.sh (+8/-0)
scripts/show-config.sh (+6/-0)
scripts/unity8log.sh (+3/-0)
telegram.desktop.in.in (+12/-0)
telegram.in (+3/-0)
telegram.pub (+9/-0)
telegram.qml (+434/-0)
tests/autopilot/run (+11/-0)
tests/autopilot/uitest/__init__.py (+71/-0)
tests/autopilot/uitest/test_main.py (+24/-0)
tests/unit/tst_hellocomponent.qml (+49/-0)
tools/enter-lxc.sh (+10/-0)
tools/extract_suppressions.sh (+57/-0)
ui/AddContactPage.qml (+259/-0)
ui/CMakeLists.txt (+7/-0)
ui/ContactsPage.qml (+404/-0)
ui/DialogPage.qml (+396/-0)
ui/DialogsPage.qml (+153/-0)
ui/IntroPage.qml (+134/-0)
ui/IntroPageListModel.qml (+32/-0)
ui/PreviewPage.qml (+38/-0)
ui/ProfilePage.qml (+189/-0)
ui/SettingsPage.qml (+165/-0)
ui/SignInPage.qml (+206/-0)
ui/SignUpPage.qml (+124/-0)
ui/VerificationCodePage.qml (+203/-0)
Conflict adding file .bzrignore.  Moved existing file to .bzrignore.moved.
Conflict adding file CMakeLists.txt.  Moved existing file to CMakeLists.txt.moved.
Conflict adding file LICENSE.  Moved existing file to LICENSE.moved.
Conflict adding file build.sh.  Moved existing file to build.sh.moved.
Conflict adding file run.sh.  Moved existing file to run.sh.moved.
Conflict adding file tests.  Moved existing file to tests.moved.
To merge this branch: bzr merge lp:~vtuson/telegram-app/libqtelegram_bug1379417
Reviewer Review Type Date Requested Status
Michał Karnicki Pending
Review via email: mp+238058@code.launchpad.net

Description of the change

separated the mouse area from the picture so it covers a sourranding area, also moved the picture to the left, as I think most of the problem is the right edge eating the mouse events.

To post a comment you must log in.
Revision history for this message
Michał Karnicki (karni) wrote :

I know this is old, just doing clean-up.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== added file '.bzrignore'
2--- .bzrignore 1970-01-01 00:00:00 +0000
3+++ .bzrignore 2014-10-11 18:44:23 +0000
4@@ -0,0 +1,20 @@
5+build
6+click
7+*.click
8+library
9+CMakeLists.txt.user
10+telegram.qmlproject.user
11+manifest.json
12+telegram.desktop
13+schema.sql
14+js/version.js
15+push.py
16+Makefile
17+CMakeFiles
18+*.gmo
19+CMakeCache.txt
20+cmake_install.cmake
21+third_party
22+*.desktop.in.in.h
23+install_manifest.txt
24+ignore
25
26=== renamed file '.bzrignore' => '.bzrignore.moved'
27=== added file '.excludes'
28=== added file 'CMakeLists.txt'
29--- CMakeLists.txt 1970-01-01 00:00:00 +0000
30+++ CMakeLists.txt 2014-10-11 18:44:23 +0000
31@@ -0,0 +1,158 @@
32+project(com.ubuntu.telegram CXX)
33+cmake_minimum_required(VERSION 2.8.10)
34+find_program(INTLTOOL_MERGE intltool-merge)
35+if(NOT INTLTOOL_MERGE)
36+ message(FATAL_ERROR "Could not find intltool-merge, please install the intltool package")
37+endif()
38+find_program(INTLTOOL_EXTRACT intltool-extract)
39+if(NOT INTLTOOL_EXTRACT)
40+ message(FATAL_ERROR "Could not find intltool-extract, please install the intltool package")
41+endif()
42+
43+# For now, treat this as QML project. We may leverage "ClickApp" project later.
44+#set(UBUNTU_PROJECT_TYPE "ClickApp" CACHE INTERNAL "Tells QtCreator this is a Click application project")
45+
46+option(CLICK_MODE "Installs to a contained location" on)
47+
48+# TODO set BZR_SOURCE
49+
50+# Sets BZR_REVNO
51+execute_process(
52+ COMMAND bzr revno ${CMAKE_SOURCE_DIR}
53+ OUTPUT_VARIABLE BZR_REVNO
54+ OUTPUT_STRIP_TRAILING_WHITESPACE
55+)
56+# Sets VERSION_TAG
57+execute_process(
58+ COMMAND bzr tags -d ${CMAKE_SOURCE_DIR}
59+ COMMAND tail -n1
60+ COMMAND tr -s " "
61+ COMMAND cut -d " " -f1
62+ OUTPUT_VARIABLE VERSION_TAG
63+ OUTPUT_STRIP_TRAILING_WHITESPACE
64+)
65+# Sets VERSION_REV
66+execute_process(
67+ COMMAND bzr tags -d ${CMAKE_SOURCE_DIR}
68+ COMMAND tail -n1
69+ COMMAND tr -s " "
70+ COMMAND cut -d " " -f2
71+ OUTPUT_VARIABLE VERSION_REV
72+ OUTPUT_STRIP_TRAILING_WHITESPACE
73+)
74+
75+set(APP_NAME "telegram")
76+set(APP_PACKAGE "com.ubuntu.${APP_NAME}")
77+set(APP_TITLE "Telegram")
78+# Semantic versioning.
79+set(APP_VERSION "${VERSION_TAG}.${VERSION_REV}")
80+
81+execute_process(
82+ COMMAND echo "var version = \"${APP_VERSION}\";"
83+ COMMAND tee "${CMAKE_SOURCE_DIR}/js/version.js"
84+)
85+
86+configure_file(
87+ ${CMAKE_CURRENT_SOURCE_DIR}/push.py.in
88+ ${CMAKE_CURRENT_SOURCE_DIR}/push.py
89+)
90+
91+message("-- app version: ${APP_VERSION}")
92+set(APP_ICON "images/telegram.png")
93+set(APP_SYMBOLIC_ICON "images/telegram_symbolic.svg")
94+
95+execute_process(
96+ COMMAND dpkg-architecture -qDEB_HOST_ARCH
97+ OUTPUT_VARIABLE ARCH
98+ OUTPUT_STRIP_TRAILING_WHITESPACE
99+)
100+execute_process(
101+ COMMAND dpkg-architecture -qDEB_HOST_MULTIARCH
102+ OUTPUT_VARIABLE ARCH_TRIPLET
103+ OUTPUT_STRIP_TRAILING_WHITESPACE
104+)
105+
106+set(ARCHITECTURE "${ARCH}")
107+set(FRAMEWORK "ubuntu-sdk-14.10-dev2")
108+
109+set(MAIN_QML "${APP_NAME}.qml")
110+set(DESKTOP_FILE "${APP_NAME}.desktop")
111+set(URLS_FILE "${APP_NAME}.url-dispatcher")
112+
113+include(GNUInstallDirs)
114+find_package(Qt5Core)
115+find_package(Qt5Qml)
116+find_package(Qt5Quick)
117+
118+set(CMAKE_AUTOMOC ON)
119+
120+set(QT_IMPORTS_DIR "lib/${ARCH_TRIPLET}")
121+
122+if(CLICK_MODE)
123+ if(NOT DEFINED BZR_SOURCE)
124+ set(BZR_SOURCE "lp:telegram-app")
125+ message("-- Setting BZR_SOURCE to ${BZR_SOURCE}")
126+ endif(NOT DEFINED BZR_SOURCE)
127+
128+ STRING(REPLACE "/usr/" "/" QT_IMPORTS_DIR ${QT_IMPORTS_DIR})
129+ set(CMAKE_INSTALL_PREFIX /)
130+ set(CMAKE_INSTALL_BINDIR /)
131+ set(DATA_DIR .)
132+ set(EXEC "qmlscene $@ ${MAIN_QML}")
133+ set(DESKTOP_DIR ${CMAKE_INSTALL_PREFIX})
134+# set(URLS_DIR ${CMAKE_INSTALL_PREFIX})
135+else()
136+ set(DATA_DIR ${CMAKE_INSTALL_FULL_DATADIR}/${APP_NAME})
137+ configure_file(${APP_NAME}.in
138+ ${CMAKE_CURRENT_BINARY_DIR}/${APP_NAME})
139+ install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${APP_NAME}
140+ DESTINATION ${CMAKE_INSTALL_BINDIR})
141+ set(EXEC ${APP_NAME})
142+ set(DESKTOP_DIR ${CMAKE_INSTALL_FULL_DATADIR}/applications)
143+# set(URLS_DIR ${CMAKE_INSTALL_DATADIR}/url-dispatcher/urls)
144+endif()
145+
146+set(ICON ${DATA_DIR}/${APP_ICON})
147+set(SYMBOLIC_ICON ${DATA_DIR}/${APP_SYMBOLIC_ICON})
148+
149+configure_file(
150+ ${CMAKE_CURRENT_SOURCE_DIR}/manifest.json.in
151+ ${CMAKE_CURRENT_SOURCE_DIR}/manifest.json
152+)
153+
154+file(GLOB_RECURSE I18N_SRC_FILES
155+ RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}/po
156+ *.qml *.js *.cpp *.h)
157+list(APPEND I18N_SRC_FILES ${DESKTOP_FILE}.in.in.h)
158+list(SORT I18N_SRC_FILES)
159+
160+configure_file(${DESKTOP_FILE}.in.in ${CMAKE_CURRENT_BINARY_DIR}/${DESKTOP_FILE}.in)
161+
162+add_custom_target(${DESKTOP_FILE} ALL
163+ COMMENT "Merging translations into ${DESKTOP_FILE}"
164+ COMMAND LC_ALL=C ${INTLTOOL_MERGE} -d -u ${CMAKE_SOURCE_DIR}/po ${DESKTOP_FILE}.in ${DESKTOP_FILE} > /dev/null
165+)
166+install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${DESKTOP_FILE} DESTINATION ${DESKTOP_DIR})
167+
168+#install(
169+# FILES ${URLS_FILE}
170+# DESTINATION ${URLS_DIR}
171+#)
172+install(FILES manifest.json DESTINATION ${CMAKE_INSTALL_PREFIX})
173+install(FILES "apparmor-telegram.json" DESTINATION ${DATA_DIR})
174+install(FILES "push.json" DESTINATION ${DATA_DIR})
175+install(FILES "apparmor-push.json" DESTINATION ${DATA_DIR})
176+install(FILES "push.py" DESTINATION ${DATA_DIR})
177+install(FILES "telegram.qml" DESTINATION ${DATA_DIR})
178+install(FILES "telegram.pub" DESTINATION ${DATA_DIR})
179+install(DIRECTORY "assets" DESTINATION ${DATA_DIR})
180+install(DIRECTORY "images" DESTINATION ${DATA_DIR})
181+install(DIRECTORY "ui" DESTINATION ${DATA_DIR})
182+install(DIRECTORY "js" DESTINATION ${DATA_DIR})
183+
184+# Ensure all source files appear in QtCreator's UI
185+add_subdirectory(library)
186+add_subdirectory(components)
187+add_subdirectory(po)
188+file(GLOB QML_JS_FILES *.qml *.js ui/*.qml js/*.js)
189+add_custom_target(QML_JS_TARGET ALL SOURCES ${QML_JS_FILES})
190
191=== renamed file 'CMakeLists.txt' => 'CMakeLists.txt.moved'
192=== added file 'LICENSE'
193--- LICENSE 1970-01-01 00:00:00 +0000
194+++ LICENSE 2014-10-11 18:44:23 +0000
195@@ -0,0 +1,674 @@
196+ GNU GENERAL PUBLIC LICENSE
197+ Version 3, 29 June 2007
198+
199+ Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
200+ Everyone is permitted to copy and distribute verbatim copies
201+ of this license document, but changing it is not allowed.
202+
203+ Preamble
204+
205+ The GNU General Public License is a free, copyleft license for
206+software and other kinds of works.
207+
208+ The licenses for most software and other practical works are designed
209+to take away your freedom to share and change the works. By contrast,
210+the GNU General Public License is intended to guarantee your freedom to
211+share and change all versions of a program--to make sure it remains free
212+software for all its users. We, the Free Software Foundation, use the
213+GNU General Public License for most of our software; it applies also to
214+any other work released this way by its authors. You can apply it to
215+your programs, too.
216+
217+ When we speak of free software, we are referring to freedom, not
218+price. Our General Public Licenses are designed to make sure that you
219+have the freedom to distribute copies of free software (and charge for
220+them if you wish), that you receive source code or can get it if you
221+want it, that you can change the software or use pieces of it in new
222+free programs, and that you know you can do these things.
223+
224+ To protect your rights, we need to prevent others from denying you
225+these rights or asking you to surrender the rights. Therefore, you have
226+certain responsibilities if you distribute copies of the software, or if
227+you modify it: responsibilities to respect the freedom of others.
228+
229+ For example, if you distribute copies of such a program, whether
230+gratis or for a fee, you must pass on to the recipients the same
231+freedoms that you received. You must make sure that they, too, receive
232+or can get the source code. And you must show them these terms so they
233+know their rights.
234+
235+ Developers that use the GNU GPL protect your rights with two steps:
236+(1) assert copyright on the software, and (2) offer you this License
237+giving you legal permission to copy, distribute and/or modify it.
238+
239+ For the developers' and authors' protection, the GPL clearly explains
240+that there is no warranty for this free software. For both users' and
241+authors' sake, the GPL requires that modified versions be marked as
242+changed, so that their problems will not be attributed erroneously to
243+authors of previous versions.
244+
245+ Some devices are designed to deny users access to install or run
246+modified versions of the software inside them, although the manufacturer
247+can do so. This is fundamentally incompatible with the aim of
248+protecting users' freedom to change the software. The systematic
249+pattern of such abuse occurs in the area of products for individuals to
250+use, which is precisely where it is most unacceptable. Therefore, we
251+have designed this version of the GPL to prohibit the practice for those
252+products. If such problems arise substantially in other domains, we
253+stand ready to extend this provision to those domains in future versions
254+of the GPL, as needed to protect the freedom of users.
255+
256+ Finally, every program is threatened constantly by software patents.
257+States should not allow patents to restrict development and use of
258+software on general-purpose computers, but in those that do, we wish to
259+avoid the special danger that patents applied to a free program could
260+make it effectively proprietary. To prevent this, the GPL assures that
261+patents cannot be used to render the program non-free.
262+
263+ The precise terms and conditions for copying, distribution and
264+modification follow.
265+
266+ TERMS AND CONDITIONS
267+
268+ 0. Definitions.
269+
270+ "This License" refers to version 3 of the GNU General Public License.
271+
272+ "Copyright" also means copyright-like laws that apply to other kinds of
273+works, such as semiconductor masks.
274+
275+ "The Program" refers to any copyrightable work licensed under this
276+License. Each licensee is addressed as "you". "Licensees" and
277+"recipients" may be individuals or organizations.
278+
279+ To "modify" a work means to copy from or adapt all or part of the work
280+in a fashion requiring copyright permission, other than the making of an
281+exact copy. The resulting work is called a "modified version" of the
282+earlier work or a work "based on" the earlier work.
283+
284+ A "covered work" means either the unmodified Program or a work based
285+on the Program.
286+
287+ To "propagate" a work means to do anything with it that, without
288+permission, would make you directly or secondarily liable for
289+infringement under applicable copyright law, except executing it on a
290+computer or modifying a private copy. Propagation includes copying,
291+distribution (with or without modification), making available to the
292+public, and in some countries other activities as well.
293+
294+ To "convey" a work means any kind of propagation that enables other
295+parties to make or receive copies. Mere interaction with a user through
296+a computer network, with no transfer of a copy, is not conveying.
297+
298+ An interactive user interface displays "Appropriate Legal Notices"
299+to the extent that it includes a convenient and prominently visible
300+feature that (1) displays an appropriate copyright notice, and (2)
301+tells the user that there is no warranty for the work (except to the
302+extent that warranties are provided), that licensees may convey the
303+work under this License, and how to view a copy of this License. If
304+the interface presents a list of user commands or options, such as a
305+menu, a prominent item in the list meets this criterion.
306+
307+ 1. Source Code.
308+
309+ The "source code" for a work means the preferred form of the work
310+for making modifications to it. "Object code" means any non-source
311+form of a work.
312+
313+ A "Standard Interface" means an interface that either is an official
314+standard defined by a recognized standards body, or, in the case of
315+interfaces specified for a particular programming language, one that
316+is widely used among developers working in that language.
317+
318+ The "System Libraries" of an executable work include anything, other
319+than the work as a whole, that (a) is included in the normal form of
320+packaging a Major Component, but which is not part of that Major
321+Component, and (b) serves only to enable use of the work with that
322+Major Component, or to implement a Standard Interface for which an
323+implementation is available to the public in source code form. A
324+"Major Component", in this context, means a major essential component
325+(kernel, window system, and so on) of the specific operating system
326+(if any) on which the executable work runs, or a compiler used to
327+produce the work, or an object code interpreter used to run it.
328+
329+ The "Corresponding Source" for a work in object code form means all
330+the source code needed to generate, install, and (for an executable
331+work) run the object code and to modify the work, including scripts to
332+control those activities. However, it does not include the work's
333+System Libraries, or general-purpose tools or generally available free
334+programs which are used unmodified in performing those activities but
335+which are not part of the work. For example, Corresponding Source
336+includes interface definition files associated with source files for
337+the work, and the source code for shared libraries and dynamically
338+linked subprograms that the work is specifically designed to require,
339+such as by intimate data communication or control flow between those
340+subprograms and other parts of the work.
341+
342+ The Corresponding Source need not include anything that users
343+can regenerate automatically from other parts of the Corresponding
344+Source.
345+
346+ The Corresponding Source for a work in source code form is that
347+same work.
348+
349+ 2. Basic Permissions.
350+
351+ All rights granted under this License are granted for the term of
352+copyright on the Program, and are irrevocable provided the stated
353+conditions are met. This License explicitly affirms your unlimited
354+permission to run the unmodified Program. The output from running a
355+covered work is covered by this License only if the output, given its
356+content, constitutes a covered work. This License acknowledges your
357+rights of fair use or other equivalent, as provided by copyright law.
358+
359+ You may make, run and propagate covered works that you do not
360+convey, without conditions so long as your license otherwise remains
361+in force. You may convey covered works to others for the sole purpose
362+of having them make modifications exclusively for you, or provide you
363+with facilities for running those works, provided that you comply with
364+the terms of this License in conveying all material for which you do
365+not control copyright. Those thus making or running the covered works
366+for you must do so exclusively on your behalf, under your direction
367+and control, on terms that prohibit them from making any copies of
368+your copyrighted material outside their relationship with you.
369+
370+ Conveying under any other circumstances is permitted solely under
371+the conditions stated below. Sublicensing is not allowed; section 10
372+makes it unnecessary.
373+
374+ 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
375+
376+ No covered work shall be deemed part of an effective technological
377+measure under any applicable law fulfilling obligations under article
378+11 of the WIPO copyright treaty adopted on 20 December 1996, or
379+similar laws prohibiting or restricting circumvention of such
380+measures.
381+
382+ When you convey a covered work, you waive any legal power to forbid
383+circumvention of technological measures to the extent such circumvention
384+is effected by exercising rights under this License with respect to
385+the covered work, and you disclaim any intention to limit operation or
386+modification of the work as a means of enforcing, against the work's
387+users, your or third parties' legal rights to forbid circumvention of
388+technological measures.
389+
390+ 4. Conveying Verbatim Copies.
391+
392+ You may convey verbatim copies of the Program's source code as you
393+receive it, in any medium, provided that you conspicuously and
394+appropriately publish on each copy an appropriate copyright notice;
395+keep intact all notices stating that this License and any
396+non-permissive terms added in accord with section 7 apply to the code;
397+keep intact all notices of the absence of any warranty; and give all
398+recipients a copy of this License along with the Program.
399+
400+ You may charge any price or no price for each copy that you convey,
401+and you may offer support or warranty protection for a fee.
402+
403+ 5. Conveying Modified Source Versions.
404+
405+ You may convey a work based on the Program, or the modifications to
406+produce it from the Program, in the form of source code under the
407+terms of section 4, provided that you also meet all of these conditions:
408+
409+ a) The work must carry prominent notices stating that you modified
410+ it, and giving a relevant date.
411+
412+ b) The work must carry prominent notices stating that it is
413+ released under this License and any conditions added under section
414+ 7. This requirement modifies the requirement in section 4 to
415+ "keep intact all notices".
416+
417+ c) You must license the entire work, as a whole, under this
418+ License to anyone who comes into possession of a copy. This
419+ License will therefore apply, along with any applicable section 7
420+ additional terms, to the whole of the work, and all its parts,
421+ regardless of how they are packaged. This License gives no
422+ permission to license the work in any other way, but it does not
423+ invalidate such permission if you have separately received it.
424+
425+ d) If the work has interactive user interfaces, each must display
426+ Appropriate Legal Notices; however, if the Program has interactive
427+ interfaces that do not display Appropriate Legal Notices, your
428+ work need not make them do so.
429+
430+ A compilation of a covered work with other separate and independent
431+works, which are not by their nature extensions of the covered work,
432+and which are not combined with it such as to form a larger program,
433+in or on a volume of a storage or distribution medium, is called an
434+"aggregate" if the compilation and its resulting copyright are not
435+used to limit the access or legal rights of the compilation's users
436+beyond what the individual works permit. Inclusion of a covered work
437+in an aggregate does not cause this License to apply to the other
438+parts of the aggregate.
439+
440+ 6. Conveying Non-Source Forms.
441+
442+ You may convey a covered work in object code form under the terms
443+of sections 4 and 5, provided that you also convey the
444+machine-readable Corresponding Source under the terms of this License,
445+in one of these ways:
446+
447+ a) Convey the object code in, or embodied in, a physical product
448+ (including a physical distribution medium), accompanied by the
449+ Corresponding Source fixed on a durable physical medium
450+ customarily used for software interchange.
451+
452+ b) Convey the object code in, or embodied in, a physical product
453+ (including a physical distribution medium), accompanied by a
454+ written offer, valid for at least three years and valid for as
455+ long as you offer spare parts or customer support for that product
456+ model, to give anyone who possesses the object code either (1) a
457+ copy of the Corresponding Source for all the software in the
458+ product that is covered by this License, on a durable physical
459+ medium customarily used for software interchange, for a price no
460+ more than your reasonable cost of physically performing this
461+ conveying of source, or (2) access to copy the
462+ Corresponding Source from a network server at no charge.
463+
464+ c) Convey individual copies of the object code with a copy of the
465+ written offer to provide the Corresponding Source. This
466+ alternative is allowed only occasionally and noncommercially, and
467+ only if you received the object code with such an offer, in accord
468+ with subsection 6b.
469+
470+ d) Convey the object code by offering access from a designated
471+ place (gratis or for a charge), and offer equivalent access to the
472+ Corresponding Source in the same way through the same place at no
473+ further charge. You need not require recipients to copy the
474+ Corresponding Source along with the object code. If the place to
475+ copy the object code is a network server, the Corresponding Source
476+ may be on a different server (operated by you or a third party)
477+ that supports equivalent copying facilities, provided you maintain
478+ clear directions next to the object code saying where to find the
479+ Corresponding Source. Regardless of what server hosts the
480+ Corresponding Source, you remain obligated to ensure that it is
481+ available for as long as needed to satisfy these requirements.
482+
483+ e) Convey the object code using peer-to-peer transmission, provided
484+ you inform other peers where the object code and Corresponding
485+ Source of the work are being offered to the general public at no
486+ charge under subsection 6d.
487+
488+ A separable portion of the object code, whose source code is excluded
489+from the Corresponding Source as a System Library, need not be
490+included in conveying the object code work.
491+
492+ A "User Product" is either (1) a "consumer product", which means any
493+tangible personal property which is normally used for personal, family,
494+or household purposes, or (2) anything designed or sold for incorporation
495+into a dwelling. In determining whether a product is a consumer product,
496+doubtful cases shall be resolved in favor of coverage. For a particular
497+product received by a particular user, "normally used" refers to a
498+typical or common use of that class of product, regardless of the status
499+of the particular user or of the way in which the particular user
500+actually uses, or expects or is expected to use, the product. A product
501+is a consumer product regardless of whether the product has substantial
502+commercial, industrial or non-consumer uses, unless such uses represent
503+the only significant mode of use of the product.
504+
505+ "Installation Information" for a User Product means any methods,
506+procedures, authorization keys, or other information required to install
507+and execute modified versions of a covered work in that User Product from
508+a modified version of its Corresponding Source. The information must
509+suffice to ensure that the continued functioning of the modified object
510+code is in no case prevented or interfered with solely because
511+modification has been made.
512+
513+ If you convey an object code work under this section in, or with, or
514+specifically for use in, a User Product, and the conveying occurs as
515+part of a transaction in which the right of possession and use of the
516+User Product is transferred to the recipient in perpetuity or for a
517+fixed term (regardless of how the transaction is characterized), the
518+Corresponding Source conveyed under this section must be accompanied
519+by the Installation Information. But this requirement does not apply
520+if neither you nor any third party retains the ability to install
521+modified object code on the User Product (for example, the work has
522+been installed in ROM).
523+
524+ The requirement to provide Installation Information does not include a
525+requirement to continue to provide support service, warranty, or updates
526+for a work that has been modified or installed by the recipient, or for
527+the User Product in which it has been modified or installed. Access to a
528+network may be denied when the modification itself materially and
529+adversely affects the operation of the network or violates the rules and
530+protocols for communication across the network.
531+
532+ Corresponding Source conveyed, and Installation Information provided,
533+in accord with this section must be in a format that is publicly
534+documented (and with an implementation available to the public in
535+source code form), and must require no special password or key for
536+unpacking, reading or copying.
537+
538+ 7. Additional Terms.
539+
540+ "Additional permissions" are terms that supplement the terms of this
541+License by making exceptions from one or more of its conditions.
542+Additional permissions that are applicable to the entire Program shall
543+be treated as though they were included in this License, to the extent
544+that they are valid under applicable law. If additional permissions
545+apply only to part of the Program, that part may be used separately
546+under those permissions, but the entire Program remains governed by
547+this License without regard to the additional permissions.
548+
549+ When you convey a copy of a covered work, you may at your option
550+remove any additional permissions from that copy, or from any part of
551+it. (Additional permissions may be written to require their own
552+removal in certain cases when you modify the work.) You may place
553+additional permissions on material, added by you to a covered work,
554+for which you have or can give appropriate copyright permission.
555+
556+ Notwithstanding any other provision of this License, for material you
557+add to a covered work, you may (if authorized by the copyright holders of
558+that material) supplement the terms of this License with terms:
559+
560+ a) Disclaiming warranty or limiting liability differently from the
561+ terms of sections 15 and 16 of this License; or
562+
563+ b) Requiring preservation of specified reasonable legal notices or
564+ author attributions in that material or in the Appropriate Legal
565+ Notices displayed by works containing it; or
566+
567+ c) Prohibiting misrepresentation of the origin of that material, or
568+ requiring that modified versions of such material be marked in
569+ reasonable ways as different from the original version; or
570+
571+ d) Limiting the use for publicity purposes of names of licensors or
572+ authors of the material; or
573+
574+ e) Declining to grant rights under trademark law for use of some
575+ trade names, trademarks, or service marks; or
576+
577+ f) Requiring indemnification of licensors and authors of that
578+ material by anyone who conveys the material (or modified versions of
579+ it) with contractual assumptions of liability to the recipient, for
580+ any liability that these contractual assumptions directly impose on
581+ those licensors and authors.
582+
583+ All other non-permissive additional terms are considered "further
584+restrictions" within the meaning of section 10. If the Program as you
585+received it, or any part of it, contains a notice stating that it is
586+governed by this License along with a term that is a further
587+restriction, you may remove that term. If a license document contains
588+a further restriction but permits relicensing or conveying under this
589+License, you may add to a covered work material governed by the terms
590+of that license document, provided that the further restriction does
591+not survive such relicensing or conveying.
592+
593+ If you add terms to a covered work in accord with this section, you
594+must place, in the relevant source files, a statement of the
595+additional terms that apply to those files, or a notice indicating
596+where to find the applicable terms.
597+
598+ Additional terms, permissive or non-permissive, may be stated in the
599+form of a separately written license, or stated as exceptions;
600+the above requirements apply either way.
601+
602+ 8. Termination.
603+
604+ You may not propagate or modify a covered work except as expressly
605+provided under this License. Any attempt otherwise to propagate or
606+modify it is void, and will automatically terminate your rights under
607+this License (including any patent licenses granted under the third
608+paragraph of section 11).
609+
610+ However, if you cease all violation of this License, then your
611+license from a particular copyright holder is reinstated (a)
612+provisionally, unless and until the copyright holder explicitly and
613+finally terminates your license, and (b) permanently, if the copyright
614+holder fails to notify you of the violation by some reasonable means
615+prior to 60 days after the cessation.
616+
617+ Moreover, your license from a particular copyright holder is
618+reinstated permanently if the copyright holder notifies you of the
619+violation by some reasonable means, this is the first time you have
620+received notice of violation of this License (for any work) from that
621+copyright holder, and you cure the violation prior to 30 days after
622+your receipt of the notice.
623+
624+ Termination of your rights under this section does not terminate the
625+licenses of parties who have received copies or rights from you under
626+this License. If your rights have been terminated and not permanently
627+reinstated, you do not qualify to receive new licenses for the same
628+material under section 10.
629+
630+ 9. Acceptance Not Required for Having Copies.
631+
632+ You are not required to accept this License in order to receive or
633+run a copy of the Program. Ancillary propagation of a covered work
634+occurring solely as a consequence of using peer-to-peer transmission
635+to receive a copy likewise does not require acceptance. However,
636+nothing other than this License grants you permission to propagate or
637+modify any covered work. These actions infringe copyright if you do
638+not accept this License. Therefore, by modifying or propagating a
639+covered work, you indicate your acceptance of this License to do so.
640+
641+ 10. Automatic Licensing of Downstream Recipients.
642+
643+ Each time you convey a covered work, the recipient automatically
644+receives a license from the original licensors, to run, modify and
645+propagate that work, subject to this License. You are not responsible
646+for enforcing compliance by third parties with this License.
647+
648+ An "entity transaction" is a transaction transferring control of an
649+organization, or substantially all assets of one, or subdividing an
650+organization, or merging organizations. If propagation of a covered
651+work results from an entity transaction, each party to that
652+transaction who receives a copy of the work also receives whatever
653+licenses to the work the party's predecessor in interest had or could
654+give under the previous paragraph, plus a right to possession of the
655+Corresponding Source of the work from the predecessor in interest, if
656+the predecessor has it or can get it with reasonable efforts.
657+
658+ You may not impose any further restrictions on the exercise of the
659+rights granted or affirmed under this License. For example, you may
660+not impose a license fee, royalty, or other charge for exercise of
661+rights granted under this License, and you may not initiate litigation
662+(including a cross-claim or counterclaim in a lawsuit) alleging that
663+any patent claim is infringed by making, using, selling, offering for
664+sale, or importing the Program or any portion of it.
665+
666+ 11. Patents.
667+
668+ A "contributor" is a copyright holder who authorizes use under this
669+License of the Program or a work on which the Program is based. The
670+work thus licensed is called the contributor's "contributor version".
671+
672+ A contributor's "essential patent claims" are all patent claims
673+owned or controlled by the contributor, whether already acquired or
674+hereafter acquired, that would be infringed by some manner, permitted
675+by this License, of making, using, or selling its contributor version,
676+but do not include claims that would be infringed only as a
677+consequence of further modification of the contributor version. For
678+purposes of this definition, "control" includes the right to grant
679+patent sublicenses in a manner consistent with the requirements of
680+this License.
681+
682+ Each contributor grants you a non-exclusive, worldwide, royalty-free
683+patent license under the contributor's essential patent claims, to
684+make, use, sell, offer for sale, import and otherwise run, modify and
685+propagate the contents of its contributor version.
686+
687+ In the following three paragraphs, a "patent license" is any express
688+agreement or commitment, however denominated, not to enforce a patent
689+(such as an express permission to practice a patent or covenant not to
690+sue for patent infringement). To "grant" such a patent license to a
691+party means to make such an agreement or commitment not to enforce a
692+patent against the party.
693+
694+ If you convey a covered work, knowingly relying on a patent license,
695+and the Corresponding Source of the work is not available for anyone
696+to copy, free of charge and under the terms of this License, through a
697+publicly available network server or other readily accessible means,
698+then you must either (1) cause the Corresponding Source to be so
699+available, or (2) arrange to deprive yourself of the benefit of the
700+patent license for this particular work, or (3) arrange, in a manner
701+consistent with the requirements of this License, to extend the patent
702+license to downstream recipients. "Knowingly relying" means you have
703+actual knowledge that, but for the patent license, your conveying the
704+covered work in a country, or your recipient's use of the covered work
705+in a country, would infringe one or more identifiable patents in that
706+country that you have reason to believe are valid.
707+
708+ If, pursuant to or in connection with a single transaction or
709+arrangement, you convey, or propagate by procuring conveyance of, a
710+covered work, and grant a patent license to some of the parties
711+receiving the covered work authorizing them to use, propagate, modify
712+or convey a specific copy of the covered work, then the patent license
713+you grant is automatically extended to all recipients of the covered
714+work and works based on it.
715+
716+ A patent license is "discriminatory" if it does not include within
717+the scope of its coverage, prohibits the exercise of, or is
718+conditioned on the non-exercise of one or more of the rights that are
719+specifically granted under this License. You may not convey a covered
720+work if you are a party to an arrangement with a third party that is
721+in the business of distributing software, under which you make payment
722+to the third party based on the extent of your activity of conveying
723+the work, and under which the third party grants, to any of the
724+parties who would receive the covered work from you, a discriminatory
725+patent license (a) in connection with copies of the covered work
726+conveyed by you (or copies made from those copies), or (b) primarily
727+for and in connection with specific products or compilations that
728+contain the covered work, unless you entered into that arrangement,
729+or that patent license was granted, prior to 28 March 2007.
730+
731+ Nothing in this License shall be construed as excluding or limiting
732+any implied license or other defenses to infringement that may
733+otherwise be available to you under applicable patent law.
734+
735+ 12. No Surrender of Others' Freedom.
736+
737+ If conditions are imposed on you (whether by court order, agreement or
738+otherwise) that contradict the conditions of this License, they do not
739+excuse you from the conditions of this License. If you cannot convey a
740+covered work so as to satisfy simultaneously your obligations under this
741+License and any other pertinent obligations, then as a consequence you may
742+not convey it at all. For example, if you agree to terms that obligate you
743+to collect a royalty for further conveying from those to whom you convey
744+the Program, the only way you could satisfy both those terms and this
745+License would be to refrain entirely from conveying the Program.
746+
747+ 13. Use with the GNU Affero General Public License.
748+
749+ Notwithstanding any other provision of this License, you have
750+permission to link or combine any covered work with a work licensed
751+under version 3 of the GNU Affero General Public License into a single
752+combined work, and to convey the resulting work. The terms of this
753+License will continue to apply to the part which is the covered work,
754+but the special requirements of the GNU Affero General Public License,
755+section 13, concerning interaction through a network will apply to the
756+combination as such.
757+
758+ 14. Revised Versions of this License.
759+
760+ The Free Software Foundation may publish revised and/or new versions of
761+the GNU General Public License from time to time. Such new versions will
762+be similar in spirit to the present version, but may differ in detail to
763+address new problems or concerns.
764+
765+ Each version is given a distinguishing version number. If the
766+Program specifies that a certain numbered version of the GNU General
767+Public License "or any later version" applies to it, you have the
768+option of following the terms and conditions either of that numbered
769+version or of any later version published by the Free Software
770+Foundation. If the Program does not specify a version number of the
771+GNU General Public License, you may choose any version ever published
772+by the Free Software Foundation.
773+
774+ If the Program specifies that a proxy can decide which future
775+versions of the GNU General Public License can be used, that proxy's
776+public statement of acceptance of a version permanently authorizes you
777+to choose that version for the Program.
778+
779+ Later license versions may give you additional or different
780+permissions. However, no additional obligations are imposed on any
781+author or copyright holder as a result of your choosing to follow a
782+later version.
783+
784+ 15. Disclaimer of Warranty.
785+
786+ THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
787+APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
788+HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
789+OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
790+THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
791+PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
792+IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
793+ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
794+
795+ 16. Limitation of Liability.
796+
797+ IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
798+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
799+THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
800+GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
801+USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
802+DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
803+PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
804+EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
805+SUCH DAMAGES.
806+
807+ 17. Interpretation of Sections 15 and 16.
808+
809+ If the disclaimer of warranty and limitation of liability provided
810+above cannot be given local legal effect according to their terms,
811+reviewing courts shall apply local law that most closely approximates
812+an absolute waiver of all civil liability in connection with the
813+Program, unless a warranty or assumption of liability accompanies a
814+copy of the Program in return for a fee.
815+
816+ END OF TERMS AND CONDITIONS
817+
818+ How to Apply These Terms to Your New Programs
819+
820+ If you develop a new program, and you want it to be of the greatest
821+possible use to the public, the best way to achieve this is to make it
822+free software which everyone can redistribute and change under these terms.
823+
824+ To do so, attach the following notices to the program. It is safest
825+to attach them to the start of each source file to most effectively
826+state the exclusion of warranty; and each file should have at least
827+the "copyright" line and a pointer to where the full notice is found.
828+
829+ <one line to give the program's name and a brief idea of what it does.>
830+ Copyright (C) <year> <name of author>
831+
832+ This program is free software: you can redistribute it and/or modify
833+ it under the terms of the GNU General Public License as published by
834+ the Free Software Foundation, either version 3 of the License, or
835+ (at your option) any later version.
836+
837+ This program is distributed in the hope that it will be useful,
838+ but WITHOUT ANY WARRANTY; without even the implied warranty of
839+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
840+ GNU General Public License for more details.
841+
842+ You should have received a copy of the GNU General Public License
843+ along with this program. If not, see <http://www.gnu.org/licenses/>.
844+
845+Also add information on how to contact you by electronic and paper mail.
846+
847+ If the program does terminal interaction, make it output a short
848+notice like this when it starts in an interactive mode:
849+
850+ <program> Copyright (C) <year> <name of author>
851+ This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
852+ This is free software, and you are welcome to redistribute it
853+ under certain conditions; type `show c' for details.
854+
855+The hypothetical commands `show w' and `show c' should show the appropriate
856+parts of the General Public License. Of course, your program's commands
857+might be different; for a GUI interface, you would use an "about box".
858+
859+ You should also get your employer (if you work as a programmer) or school,
860+if any, to sign a "copyright disclaimer" for the program, if necessary.
861+For more information on this, and how to apply and follow the GNU GPL, see
862+<http://www.gnu.org/licenses/>.
863+
864+ The GNU General Public License does not permit incorporating your program
865+into proprietary programs. If your program is a subroutine library, you
866+may consider it more useful to permit linking proprietary applications with
867+the library. If this is what you want to do, use the GNU Lesser General
868+Public License instead of this License. But first, please read
869+<http://www.gnu.org/philosophy/why-not-lgpl.html>.
870
871=== renamed file 'LICENSE' => 'LICENSE.moved'
872=== added file 'README.md'
873--- README.md 1970-01-01 00:00:00 +0000
874+++ README.md 2014-10-11 18:44:23 +0000
875@@ -0,0 +1,195 @@
876+Telegram for Ubuntu
877+
878+Pre-requisites
879+==============
880+These instructions have been tested on:
881+
882+ 1. Ubuntu 14.04 (Trusty Tahr)
883+ 2. Ubuntu 14.10 (Utopic Unicorn)
884+
885+Ensure you have the Ubuntu SDK installed, as per:
886+ http://developer.ubuntu.com/start/ubuntu-sdk/installing-the-sdk/
887+
888+You must set two environment variables for all scripts to work properly:
889+
890+ CLICK_SDK_ARCH=armhf # a value of amd64 also supported
891+ CLICK_SDK_FRAMEWORK=ubuntu-sdk-14.10
892+
893+
894+Bootstrap your development environment
895+======================================
896+
897+ ./bootstrap.sh
898+
899+This step will call ``click chroot create`` to create the standard Ubuntu
900+click chroot build environment. It will also install the required build
901+dependencies for Telegram into the click chroot.
902+
903+If you already have the chroot and prerequisite packages installed, then
904+calling ``./bootstrap.sh`` will only fetch the latest library files.
905+
906+Once in a while, it is better to run ``./bootstrap.sh update`` to upgrade
907+the chroot and ensure it is up to date.
908+
909+
910+Building
911+========
912+
913+ ./build.sh
914+
915+This step will cross-compile Telegram in the click chroot. After running this
916+step, you may also open the project in the Ubuntu IDE, by selecting the
917+CMakeLists.txt file in the top-level directory.
918+
919+
920+Packaging
921+=========
922+
923+ ./click.sh
924+
925+This step will create an armhf click package suitable for installation on
926+an Ubuntu Phone/Tablet device. To install the package for testing:
927+
928+ ./click.sh install
929+
930+Afterwards, search for the "telegram" in the App scope, and tap the icon
931+to launch the app.
932+
933+
934+Running on Ubuntu desktop
935+=========================
936+Alternatively, it is possible to build and run on your existing Ubuntu
937+workstation (desktop or laptop).
938+
939+NOTE: this technique only works for Ubuntu 14.10 (utopic unicorn) machines
940+ using the amd64 architecture.
941+
942+To run in this mode, you must:
943+
944+ 1. set CLICK_SDK_ARCH=amd64
945+ 2. ./bootstrap.sh # creates a separate amd64 click chroot
946+ 3. ./build.sh # build for amd64 architecture
947+ 4. ./run.sh # runs app on desktop
948+
949+NOTE: you also need to install qml-module-qt-labs-settings on your host.
950+
951+NOTE: running on an Ubuntu 14.04 LTS (trusty) machine is possible using
952+ LXC, but that is an advanced technique, and out of scope for this
953+ document. If you are truly interested, please try the ``create``
954+ script from the following repo:
955+
956+ https://github.com/achiang/ubuntu-sdk-lxc
957+
958+
959+Debugging
960+=========
961+Telegram will log debug output on the phone to:
962+
963+ /home/phablet/.cache/upstart/
964+
965+The file name will resemble:
966+
967+ application-click-com.ubuntu.telegram_telegram_0.2.0+2.log
968+
969+But will change depending on the version number. Another common error may
970+be AppArmor denials. To view those:
971+
972+ grep DENIED /var/log/syslog | grep telegram
973+
974+If Telegram crashes, it will create crash files similar to:
975+
976+ /var/crash/_usr_lib_arm-linux-gnueabihf_qt5_bin_qmlscene.32011.crash
977+
978+If there are also files named *.upload and *.uploaded, it means that the
979+Ubuntu system error logger (named ``whoopsie``) has uploaded them to
980+
981+ https://errors.ubuntu.com/
982+
983+You must login to the page using your Ubuntu SSO credentials. Then you can
984+find your crash's stack trace by navigating to:
985+
986+ https://errors.ubuntu.com/oops/<OOPS-ID>
987+
988+To find the OOP-ID, view:
989+
990+ /var/crash/upstart/whoopsie.log
991+
992+And search for a line that resembles:
993+
994+ Reported OOPS ID 4923130e-1879-11e4-ab04-fa163e339c81
995+
996+The long hex string should be entered into the URL above (without the angle
997+brackets).
998+
999+If whoopsie did not upload the crash to the Ubuntu error tracker, you can
1000+still analyze the crash locally. Use ``adb pull`` to copy the *.crash file
1001+onto your development machine. Then:
1002+
1003+ sudo apt-get install apport-retrace
1004+ apport-cli <name of crash file>
1005+
1006+You can then follow the menu options to 'V'iew the trace locally. The other
1007+option is to install ``apport-retrace`` on your device itself, and directly
1008+issue:
1009+
1010+ apport-retrace <name of crash file>
1011+
1012+Finally, please file all bugs to:
1013+
1014+ https://bugs.launchpad.net/libqtelegram
1015+
1016+
1017+Development
1018+===========
1019+
1020+These are the important branches:
1021+
1022+ lp:libqtelegram
1023+
1024+ - the trunk of the libqtelegram library
1025+
1026+ lp:libqtelegram/dev
1027+
1028+ - the devel branch of the libqtelegram library
1029+
1030+ lp:libqtelegram/app
1031+
1032+ - the trunk of the Telegram app
1033+
1034+ lp:libqtelegram/app-dev
1035+
1036+ - the devel branch of the Telegram app
1037+
1038+Propose Telegram application merges to this branch:
1039+
1040+ lp:libqtelegram/app-dev
1041+
1042+Propose libqtelegram library merges to this branch:
1043+
1044+ lp:libqtelegram/dev
1045+
1046+
1047+More or less on the weekly basis, we land the devel branches to trunks.
1048+
1049+bzr tagging of lp:libqtelegram/app:
1050+Once a new page of the app is feature ready, bump the MINOR version.
1051+For backward compatible bug fixes, bump the PATCH version.
1052+
1053+ bzr tag MAJOR.MINOR.PATCH
1054+
1055+Building in the IDE is not fully supported, but you can try.
1056+
1057+ * be sure to import CMakeLists.txt
1058+ * add -DCLICK_MODE=on as a cmake command line arg
1059+
1060+
1061+Credits
1062+=======
1063+Telegram for Ubuntu uses libqtelegram, a Telegram library written in Qt,
1064+based on telegram-cli @ https://github.com/vysheng/tg
1065+
1066+
1067+Contact
1068+=======
1069+rmescandon and karni @ irc.freenode.net
1070+
1071
1072=== added file 'README.translations'
1073--- README.translations 1970-01-01 00:00:00 +0000
1074+++ README.translations 2014-10-11 18:44:23 +0000
1075@@ -0,0 +1,35 @@
1076+# Updating translations
1077+
1078+Translations for the Telegram app happen in [Launchpad Translations][] and
1079+are automatically committed daily on the trunk branch in the po/ folder.
1080+
1081+They are then built and installed as part of the package build, so that
1082+developers don't really need to worry about them.
1083+
1084+However, there is one task that needs to be taken care of: exposing new
1085+translatable messages to translators. So whenever you add new translatable
1086+messages in the code, make sure to follow these steps:
1087+
1088+ 1. Run click-buddy retaining the build directory:
1089+ `click-buddy --dir . --no-clean`
1090+ 2. Commit and push the branch and send a merge proposal as usual
1091+
1092+And that's it, once the branch lands Launchpad should take care of all the rest!
1093+
1094+# Behind the scenes
1095+
1096+Behind the scenes, whenever the po/*.pot file (also known as translations template)
1097+is committed to trunk Launchpad reads it and updates the translatable strings
1098+exposed in the web UI. This will enable translators to work on the new strings.
1099+The translations template contains all translatable strings that have been
1100+extracted from the source code files.
1101+
1102+Launchpad will then store translations in its database and will commit them daily
1103+in the form of textual po/*.po files to trunk. The PO files are also usually
1104+referred to as the translations files. You'll find a translation file for each
1105+language the app has got at least a translated message available for.
1106+
1107+Translations for core apps follow the standard [gettext format][].
1108+
1109+ [Launchpad Translations]: https://translations.launchpad.net/libqtelegram
1110+ [gettext format]: https://www.gnu.org/software/gettext/
1111
1112=== added file 'apparmor-push.json'
1113--- apparmor-push.json 1970-01-01 00:00:00 +0000
1114+++ apparmor-push.json 2014-10-11 18:44:23 +0000
1115@@ -0,0 +1,7 @@
1116+{
1117+ "template": "ubuntu-push-helper",
1118+ "policy_groups": [
1119+ "push-notification-client"
1120+ ],
1121+ "policy_version": 1.2
1122+}
1123
1124=== added file 'apparmor-telegram.json'
1125--- apparmor-telegram.json 1970-01-01 00:00:00 +0000
1126+++ apparmor-telegram.json 2014-10-11 18:44:23 +0000
1127@@ -0,0 +1,11 @@
1128+{
1129+ "policy_groups": [
1130+ "networking",
1131+ "connectivity",
1132+ "content_exchange",
1133+ "audio",
1134+ "webview",
1135+ "push-notification-client"
1136+ ],
1137+ "policy_version": 1.2
1138+}
1139
1140=== added directory 'assets'
1141=== added directory 'assets/sound'
1142=== added file 'assets/sound/sound_a.wav'
1143Binary files assets/sound/sound_a.wav 1970-01-01 00:00:00 +0000 and assets/sound/sound_a.wav 2014-10-11 18:44:23 +0000 differ
1144=== added file 'bootstrap.sh'
1145--- bootstrap.sh 1970-01-01 00:00:00 +0000
1146+++ bootstrap.sh 2014-10-11 18:44:23 +0000
1147@@ -0,0 +1,55 @@
1148+#!/bin/bash
1149+
1150+set -e
1151+
1152+: ${CLICK_SDK_ARCH:?"Need to set CLICK_SDK_ARCH non-empty"}
1153+: ${CLICK_SDK_FRAMEWORK:?"Need to set CLICK_SDK_FRAMEWORK non-empty"}
1154+SERIES=utopic
1155+CLICK_CHROOT_NAME=click
1156+
1157+echo "[LOG]: Bootstrapping development environment for Telegram..."
1158+
1159+#################################
1160+## Download libqtelegram library
1161+#################################
1162+# Point this to a feature branch, if you need to test against non-trunk.
1163+LIBQTELEGRAM_BRANCH=lp:libqtelegram
1164+echo "[LOG]: Branching ${LIBQTELEGRAM_BRANCH} and updating library files in the source tree"
1165+rm -rf library
1166+bzr branch $LIBQTELEGRAM_BRANCH library
1167+
1168+#######################
1169+## Create click chroot
1170+#######################
1171+
1172+# Function to upgrade the chroot and install the prerequisite packages
1173+update() {
1174+ click chroot -a ${CLICK_SDK_ARCH} -f ${CLICK_SDK_FRAMEWORK} -n ${CLICK_CHROOT_NAME} upgrade
1175+ click chroot -a ${CLICK_SDK_ARCH} -f ${CLICK_SDK_FRAMEWORK} -n ${CLICK_CHROOT_NAME} maint apt-get install -y \
1176+ libssl-dev:${CLICK_SDK_ARCH} \
1177+ libsqlite3-dev:${CLICK_SDK_ARCH} \
1178+ qtdeclarative5-ubuntu-telephony-phonenumber0.1 \
1179+ qml-module-qt-labs-settings \
1180+ intltool \
1181+ bzr \
1182+ --no-install-recommends
1183+}
1184+
1185+if ! click chroot -a ${CLICK_SDK_ARCH} -f ${CLICK_SDK_FRAMEWORK} -n ${CLICK_CHROOT_NAME} exists
1186+then
1187+ echo "[LOG]: Creating Ubuntu build chroot ${CLICK_SDK_FRAMEWORK}-${CLICK_SDK_ARCH} " \
1188+ "and installing prerequisite packages."
1189+ sudo /usr/share/qtcreator/ubuntu/scripts/click_create_target \
1190+ ${CLICK_SDK_ARCH} ${CLICK_SDK_FRAMEWORK} $SERIES $CLICK_CHROOT_NAME
1191+ update
1192+fi
1193+
1194+if [ "$1" == "update" ]; then
1195+ echo "[LOG]: Updating schroot and rechecking prequisite packages..."
1196+ update
1197+fi
1198+
1199+echo "-----------------------------------------"
1200+echo "[LOG]: Boostrapping complete!"
1201+echo "[LOG]: ARCHITECTURE: ${CLICK_SDK_ARCH}"
1202+echo "-----------------------------------------"
1203
1204=== added file 'build.sh'
1205--- build.sh 1970-01-01 00:00:00 +0000
1206+++ build.sh 2014-10-11 18:44:23 +0000
1207@@ -0,0 +1,23 @@
1208+#!/bin/bash
1209+
1210+set -e
1211+
1212+: ${CLICK_SDK_ARCH:?"Need to set CLICK_SDK_ARCH non-empty"}
1213+: ${CLICK_SDK_FRAMEWORK:?"Need to set CLICK_SDK_FRAMEWORK non-empty"}
1214+SERIES=utopic
1215+
1216+# XXX: uncomment if the country list ever changes...
1217+#./countries.py
1218+
1219+BUILD=build/${CLICK_SDK_ARCH}
1220+rm -rf $BUILD
1221+mkdir -p $BUILD && cd $BUILD
1222+
1223+SDK_PATH=/usr/share/qtcreator/ubuntu/scripts
1224+${SDK_PATH}/qtc_chroot_cmake ${CLICK_SDK_ARCH} ${CLICK_SDK_FRAMEWORK} $SERIES ../..
1225+${SDK_PATH}/qtc_chroot_make ${CLICK_SDK_ARCH} ${CLICK_SDK_FRAMEWORK} $SERIES
1226+
1227+echo "-------------------"
1228+echo "Done building."
1229+echo "ARCHITECTURE: ${CLICK_SDK_ARCH}"
1230+echo "-------------------"
1231
1232=== renamed file 'build.sh' => 'build.sh.moved'
1233=== added file 'clean.sh'
1234--- clean.sh 1970-01-01 00:00:00 +0000
1235+++ clean.sh 2014-10-11 18:44:23 +0000
1236@@ -0,0 +1,8 @@
1237+#!/bin/bash
1238+
1239+rm -rf build
1240+rm -rf click
1241+rm -f *.click
1242+rm -f manifest.json
1243+rm -f telegram.desktop
1244+
1245
1246=== added file 'click.sh'
1247--- click.sh 1970-01-01 00:00:00 +0000
1248+++ click.sh 2014-10-11 18:44:23 +0000
1249@@ -0,0 +1,52 @@
1250+#!/bin/bash
1251+
1252+set -e
1253+
1254+# Hardcode $ARCH for now, as it doesn't make sense to build an amd64 click
1255+# package. If we ever need to support that case, we'll use the
1256+# same environment variable detection trick as bootstrap.sh or build.sh
1257+ARCH=armhf
1258+ARCH_TRIPLET=arm-linux-gnueabihf
1259+DIR=`basename "$PWD"`
1260+
1261+PACKAGE=com.ubuntu.telegram
1262+CLICK=$(ls *.click|grep armhf|tail -n 1)
1263+
1264+rm -f *.click
1265+rm -rf click
1266+mkdir -p click
1267+mkdir -p click/lib/$ARCH_TRIPLET
1268+
1269+cp manifest.json click/
1270+cp build/armhf/telegram.desktop click/
1271+
1272+cp -a build/$ARCH/library/lib/libqtelegram.so* click/lib/$ARCH_TRIPLET
1273+cp -a build/$ARCH/library/qmlplugin/Telegram click/lib/$ARCH_TRIPLET
1274+
1275+cp apparmor-push.json click/
1276+cp push.json click/
1277+cp push.py click/
1278+
1279+cp apparmor-telegram.json click/
1280+cp telegram.qml click/
1281+cp telegram.pub click/
1282+
1283+cp -a components click/
1284+cp -a images click/
1285+cp -a assets click/
1286+cp -a ui click/
1287+cp -a js click/
1288+
1289+click build ./click
1290+
1291+echo "---------------------"
1292+echo "Done click packaging."
1293+echo "ARCHITECTURE: ${CLICK_SDK_ARCH}"
1294+echo "---------------------"
1295+
1296+if [ "$1" == "install" ]; then
1297+ CLICK=$(ls *.click|grep armhf|tail -n 1)
1298+ adb push $CLICK /tmp/
1299+ adb shell "sudo -u phablet -i pkcon install-local --allow-untrusted /tmp/$CLICK"
1300+ shift
1301+fi
1302
1303=== added directory 'components'
1304=== added file 'components/CMakeLists.txt'
1305--- components/CMakeLists.txt 1970-01-01 00:00:00 +0000
1306+++ components/CMakeLists.txt 2014-10-11 18:44:23 +0000
1307@@ -0,0 +1,9 @@
1308+file(GLOB COMPONENTS_QML_JS_FILES *.qml *.js)
1309+
1310+# make the files visible in the qtcreator tree
1311+add_custom_target(telegram_components_QMlFiles ALL SOURCES ${COMPONENTS_QML_JS_FILES})
1312+
1313+install(FILES ${COMPONENTS_QML_JS_FILES} DESTINATION ${TELEGRAM_DIR}/components)
1314+
1315+add_subdirectory(listitems)
1316+
1317
1318=== added file 'components/ContactImport.qml'
1319--- components/ContactImport.qml 1970-01-01 00:00:00 +0000
1320+++ components/ContactImport.qml 2014-10-11 18:44:23 +0000
1321@@ -0,0 +1,111 @@
1322+/*
1323+ * Copyright (C) 2012-2014 Canonical, Ltd.
1324+ *
1325+ * This program is free software; you can redistribute it and/or modify
1326+ * it under the terms of the GNU General Public License as published by
1327+ * the Free Software Foundation; version 3.
1328+ *
1329+ * This program is distributed in the hope that it will be useful,
1330+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
1331+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1332+ * GNU General Public License for more details.
1333+ *
1334+ * You should have received a copy of the GNU General Public License
1335+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
1336+ */
1337+
1338+import QtQuick 2.2
1339+import Ubuntu.Components 1.1
1340+import Ubuntu.Components.Popups 1.0 as Popups
1341+import Ubuntu.Content 0.1 as ContentHub
1342+import QtContacts 5.0
1343+
1344+Item {
1345+ id: root
1346+
1347+ property var importDialog: null
1348+
1349+ signal contactsReceived(string url);
1350+
1351+ function requestContact()
1352+ {
1353+ if (!root.importDialog) {
1354+ root.importDialog = PopupUtils.open(contentHubDialog, root)
1355+ } else {
1356+ console.warn("Import dialog already running")
1357+ }
1358+ }
1359+
1360+ Component {
1361+ id: contentHubDialog
1362+
1363+ Popups.PopupBase {
1364+ id: dialogue
1365+
1366+ property alias activeTransfer: signalConnections.target
1367+ focus: true
1368+
1369+ Rectangle {
1370+ anchors.fill: parent
1371+
1372+ ContentHub.ContentPeerPicker {
1373+ id: peerPicker
1374+
1375+ anchors.fill: parent
1376+ contentType: ContentHub.ContentType.Contacts
1377+ handler: ContentHub.ContentHandler.Source
1378+
1379+ onPeerSelected: {
1380+ peer.selectionType = ContentHub.ContentTransfer.Single
1381+ dialogue.activeTransfer = peer.request()
1382+ }
1383+
1384+ onCancelPressed: {
1385+ PopupUtils.close(root.importDialog)
1386+ }
1387+ }
1388+ }
1389+
1390+ Connections {
1391+ id: signalConnections
1392+
1393+ onStateChanged: {
1394+ var done = ((dialogue.activeTransfer.state === ContentHub.ContentTransfer.Charged) ||
1395+ (dialogue.activeTransfer.state === ContentHub.ContentTransfer.Aborted))
1396+
1397+ if (dialogue.activeTransfer.state === ContentHub.ContentTransfer.Charged) {
1398+ dialogue.hide()
1399+ if (dialogue.activeTransfer.items.length > 0) {
1400+ root.contactsReceived(dialogue.activeTransfer.items[0].url)
1401+ }
1402+ }
1403+
1404+ if (done) {
1405+ acceptTimer.restart()
1406+ }
1407+ }
1408+ }
1409+
1410+ // WORKAROUND: Work around for application becoming insensitive to touch events
1411+ // if the dialog is dismissed while the application is inactive.
1412+ // Just listening for changes to Qt.application.active doesn't appear
1413+ // to be enough to resolve this, so it seems that something else needs
1414+ // to be happening first. As such there's a potential for a race
1415+ // condition here, although as yet no problem has been encountered.
1416+ Timer {
1417+ id: acceptTimer
1418+
1419+ interval: 100
1420+ repeat: true
1421+ running: false
1422+ onTriggered: {
1423+ if(Qt.application.active) {
1424+ PopupUtils.close(root.importDialog)
1425+ }
1426+ }
1427+ }
1428+
1429+ Component.onDestruction: root.importDialog = null
1430+ }
1431+ }
1432+}
1433
1434=== added file 'components/PageLoader.qml'
1435--- components/PageLoader.qml 1970-01-01 00:00:00 +0000
1436+++ components/PageLoader.qml 2014-10-11 18:44:23 +0000
1437@@ -0,0 +1,13 @@
1438+import QtQuick 2.0
1439+
1440+Loader {
1441+ property bool valid: item !== null
1442+
1443+ active: false
1444+ asynchronous: false
1445+ anchors {
1446+ left: parent.left
1447+ bottom: parent.bottom
1448+ right: parent.right
1449+ }
1450+}
1451
1452=== added file 'components/PictureImport.qml'
1453--- components/PictureImport.qml 1970-01-01 00:00:00 +0000
1454+++ components/PictureImport.qml 2014-10-11 18:44:23 +0000
1455@@ -0,0 +1,110 @@
1456+/*
1457+ * Copyright (C) 2012-2014 Canonical, Ltd.
1458+ *
1459+ * This program is free software; you can redistribute it and/or modify
1460+ * it under the terms of the GNU General Public License as published by
1461+ * the Free Software Foundation; version 3.
1462+ *
1463+ * This program is distributed in the hope that it will be useful,
1464+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
1465+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1466+ * GNU General Public License for more details.
1467+ *
1468+ * You should have received a copy of the GNU General Public License
1469+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
1470+ */
1471+
1472+import QtQuick 2.2
1473+import Ubuntu.Components 1.1
1474+import Ubuntu.Components.Popups 1.0 as Popups
1475+import Ubuntu.Content 0.1 as ContentHub
1476+
1477+Item {
1478+ id: root
1479+
1480+ property var importDialog: null
1481+
1482+ signal pictureReceived(string pictureUrl)
1483+
1484+ function requestNewPicture()
1485+ {
1486+ if (!root.importDialog) {
1487+ root.importDialog = PopupUtils.open(contentHubDialog, root)
1488+ } else {
1489+ console.warn("Import dialog already running")
1490+ }
1491+ }
1492+
1493+ Component {
1494+ id: contentHubDialog
1495+
1496+ Popups.PopupBase {
1497+ id: dialogue
1498+
1499+ property alias activeTransfer: signalConnections.target
1500+ focus: true
1501+
1502+ Rectangle {
1503+ anchors.fill: parent
1504+
1505+ ContentHub.ContentPeerPicker {
1506+ id: peerPicker
1507+
1508+ anchors.fill: parent
1509+ contentType: ContentHub.ContentType.Pictures
1510+ handler: ContentHub.ContentHandler.Source
1511+
1512+ onPeerSelected: {
1513+ peer.selectionType = ContentHub.ContentTransfer.Single
1514+ dialogue.activeTransfer = peer.request()
1515+ }
1516+
1517+ onCancelPressed: {
1518+ PopupUtils.close(root.importDialog)
1519+ }
1520+ }
1521+ }
1522+
1523+ Connections {
1524+ id: signalConnections
1525+
1526+ onStateChanged: {
1527+ var done = ((dialogue.activeTransfer.state === ContentHub.ContentTransfer.Charged) ||
1528+ (dialogue.activeTransfer.state === ContentHub.ContentTransfer.Aborted))
1529+
1530+ if (dialogue.activeTransfer.state === ContentHub.ContentTransfer.Charged) {
1531+ dialogue.hide()
1532+ if (dialogue.activeTransfer.items.length > 0) {
1533+ root.pictureReceived(dialogue.activeTransfer.items[0].url)
1534+ }
1535+ }
1536+
1537+ if (done) {
1538+ acceptTimer.restart()
1539+ }
1540+ }
1541+ }
1542+
1543+ // WORKAROUND: Work around for application becoming insensitive to touch events
1544+ // if the dialog is dismissed while the application is inactive.
1545+ // Just listening for changes to Qt.application.active doesn't appear
1546+ // to be enough to resolve this, so it seems that something else needs
1547+ // to be happening first. As such there's a potential for a race
1548+ // condition here, although as yet no problem has been encountered.
1549+ Timer {
1550+ id: acceptTimer
1551+
1552+ interval: 100
1553+ repeat: true
1554+ running: false
1555+ onTriggered: {
1556+ if(Qt.application.active) {
1557+ PopupUtils.close(root.importDialog)
1558+ }
1559+ }
1560+ }
1561+
1562+ Component.onDestruction: root.importDialog = null
1563+ }
1564+ }
1565+}
1566
1567=== added file 'components/SentPhraseBubble.qml'
1568--- components/SentPhraseBubble.qml 1970-01-01 00:00:00 +0000
1569+++ components/SentPhraseBubble.qml 2014-10-11 18:44:23 +0000
1570@@ -0,0 +1,41 @@
1571+import QtQuick 2.0
1572+import Ubuntu.Components 0.1
1573+
1574+UbuntuShape {
1575+
1576+ property alias text : phrase.text
1577+
1578+ //anchors.right: parent.right
1579+
1580+ width: (parent.width * 0.8 > childrenRect.width) ? parent.width * 0.8 : childrenRect.width
1581+ //width: childrenRect.width
1582+ height: childrenRect.height
1583+
1584+ color: "lightgreen"
1585+
1586+
1587+ Label {
1588+ id: phrase
1589+ text: "que tal estas?"
1590+ }
1591+ Label {
1592+ id: date
1593+ anchors {
1594+ left: phrase.right
1595+ //bottom: parent.bottom
1596+ leftMargin: units.gu(1)
1597+ }
1598+ text: "11:30"
1599+ fontSize: "small"
1600+ }
1601+ Image {
1602+ anchors {
1603+ left: date.right
1604+ //bottom: parent.bottom
1605+ leftMargin: units.gu(1)
1606+ }
1607+ source: "../images/confirm.png"
1608+ height: phrase.height /2
1609+ width: phrase.height
1610+ }
1611+}
1612
1613=== added file 'components/TelegramBubble.qml'
1614--- components/TelegramBubble.qml 1970-01-01 00:00:00 +0000
1615+++ components/TelegramBubble.qml 2014-10-11 18:44:23 +0000
1616@@ -0,0 +1,16 @@
1617+import QtQuick 2.0
1618+
1619+BorderImage {
1620+ property bool outgoing
1621+ function selectBubble() {
1622+ var fileName = "../images/conversation_";
1623+ if (outgoing) {
1624+ fileName += "outgoing.sci";
1625+ } else {
1626+ fileName += "incoming.sci";
1627+ }
1628+ return fileName;
1629+ }
1630+ onOutgoingChanged: source = selectBubble()
1631+ source: selectBubble()
1632+}
1633
1634=== added file 'components/TelegramButton.qml'
1635--- components/TelegramButton.qml 1970-01-01 00:00:00 +0000
1636+++ components/TelegramButton.qml 2014-10-11 18:44:23 +0000
1637@@ -0,0 +1,47 @@
1638+import QtQuick 2.0
1639+import "TelegramColors.js" as TelegramColors
1640+
1641+Rectangle {
1642+ property alias text: buttonLabel.text
1643+ property alias textColor: buttonLabel.color
1644+
1645+ signal clicked
1646+
1647+ width: buttonLabel.width + units.gu(5)
1648+ height: buttonLabel.height + units.gu(2)
1649+ color: enabled ? TelegramColors.blue : TelegramColors.grey
1650+ radius: 3
1651+
1652+ Behavior on color {
1653+ ColorAnimation {
1654+ duration: 300
1655+ }
1656+ }
1657+
1658+ Text {
1659+ id: buttonLabel
1660+ anchors.centerIn: parent
1661+ horizontalAlignment: TextInput.AlignHCenter
1662+ verticalAlignment: TextInput.AlignVCenter
1663+
1664+ color: TelegramColors.white
1665+ font.pixelSize: FontUtils.sizeToPixels("large")
1666+ }
1667+
1668+ MouseArea {
1669+ id: startMessaging
1670+ anchors.fill: parent
1671+
1672+ onPressed: parent.onPressed()
1673+ onReleased: parent.onReleased()
1674+ onClicked: parent.clicked()
1675+ }
1676+
1677+ function onPressed() {
1678+ color = TelegramColors.dark_blue;
1679+ }
1680+
1681+ function onReleased() {
1682+ color = TelegramColors.blue
1683+ }
1684+}
1685
1686=== added file 'components/TelegramColors.js'
1687--- components/TelegramColors.js 1970-01-01 00:00:00 +0000
1688+++ components/TelegramColors.js 2014-10-11 18:44:23 +0000
1689@@ -0,0 +1,21 @@
1690+.pragma library
1691+
1692+var black = "#000000"
1693+var white = "#ffffff"
1694+var grey = "#777777"
1695+var blue = "#2ca5e0"
1696+var dark_blue = "#1c94cf"
1697+
1698+var page_background = "#ffffff"
1699+
1700+var unread_green = "#5ec245"
1701+var dark_green = "#267932"
1702+
1703+var list_pressed = "#efefef"
1704+
1705+var transparent = "#00000000"
1706+
1707+var outgoing = "#e6ffd1"
1708+var incoming = "#ffffff"
1709+
1710+var chat_section = "#99a6bcca"
1711
1712=== added file 'components/TelegramContactsListItem.qml'
1713--- components/TelegramContactsListItem.qml 1970-01-01 00:00:00 +0000
1714+++ components/TelegramContactsListItem.qml 2014-10-11 18:44:23 +0000
1715@@ -0,0 +1,92 @@
1716+import QtQuick 2.0
1717+import Ubuntu.Components 1.1
1718+import "TelegramColors.js" as TelegramColors
1719+
1720+MouseArea {
1721+
1722+ property alias image: image.source
1723+ property alias title: title.text
1724+ property string lastSeen
1725+ property bool isOnline: false
1726+ property bool selected: false
1727+
1728+ id: listitem
1729+ width: parent.width
1730+ height: units.gu(8)
1731+
1732+ Rectangle {
1733+ id: background
1734+ anchors.fill: parent
1735+ color: listitem.selected ? TelegramColors.blue
1736+ : listitem.pressed ? TelegramColors.list_pressed : TelegramColors.white
1737+ }
1738+
1739+ UbuntuShape {
1740+ id: imageShape
1741+ anchors {
1742+ top: parent.top
1743+ topMargin: units.dp(4)
1744+ left: parent.left
1745+ leftMargin: units.gu(2)
1746+ bottom: parent.bottom
1747+ bottomMargin: units.dp(4)
1748+ rightMargin: units.gu(1)
1749+ }
1750+ width: height
1751+
1752+ image: Image {
1753+ id: image
1754+ anchors.fill: parent
1755+ antialiasing: true
1756+ asynchronous: true
1757+ fillMode: Image.PreserveAspectFit
1758+ }
1759+ }
1760+
1761+ Text {
1762+ id: title
1763+ anchors {
1764+ top: parent.top
1765+ topMargin: units.gu(1)
1766+ left: imageShape.right
1767+ leftMargin: units.gu(1.5)
1768+ right: parent.right
1769+ rightMargin: units.gu(1)
1770+ }
1771+ verticalAlignment: TextInput.AlignVCenter
1772+
1773+ font.pixelSize: FontUtils.sizeToPixels("large")
1774+ font.weight: Font.DemiBold
1775+ color: TelegramColors.black
1776+ text: i18n.tr("Contact")
1777+ }
1778+
1779+ Text {
1780+ id: subtitle
1781+ anchors {
1782+ top: title.bottom
1783+ left: title.left
1784+ bottom: parent.bottom
1785+ bottomMargin: units.dp(4)
1786+ right: parent.right
1787+ }
1788+ verticalAlignment: TextInput.AlignVCenter
1789+
1790+ font.pixelSize: FontUtils.sizeToPixels("medium")
1791+ color: isOnline ? TelegramColors.dark_blue : TelegramColors.grey
1792+ text: i18n.tr("Last seen")
1793+ }
1794+
1795+ onLastSeenChanged: updateLastSeen(lastSeen)
1796+
1797+ onIsOnlineChanged: updateLastSeen(lastSeen)
1798+
1799+ function updateLastSeen(lastSeen) {
1800+ if (isOnline) {
1801+ subtitle.text = i18n.tr("online");
1802+ } else {
1803+ // TRANSLATORS: the argument refers to a time
1804+ subtitle.text = i18n.tr("last seen %1").arg(lastSeen);
1805+ }
1806+ }
1807+}
1808
1809=== added file 'components/TelegramDelegate.qml'
1810--- components/TelegramDelegate.qml 1970-01-01 00:00:00 +0000
1811+++ components/TelegramDelegate.qml 2014-10-11 18:44:23 +0000
1812@@ -0,0 +1,196 @@
1813+import QtQuick 2.0
1814+import Ubuntu.Components 0.1
1815+import Ubuntu.Components.ListItems 0.1 as ListItem
1816+import "../js/ba-linkify.js" as BaLinkify
1817+import "TelegramColors.js" as Color
1818+import Telegram 0.1
1819+
1820+Item {
1821+ property bool outgoing: false
1822+ property string message: ""
1823+ property int mediaType: 0
1824+ property string senderColor: ""
1825+ property string senderName: ""
1826+ property string senderImage: ""
1827+ property string time: ""
1828+ property string thumbnail: ""
1829+ property bool sent: false
1830+
1831+ property string textColor: outgoing ? "white" : "#333333"
1832+
1833+ id: messageDelegate
1834+ anchors {
1835+ left: parent ? parent.left : undefined
1836+ right: parent ? parent.right : undefined
1837+ }
1838+ height: internalDelegate.height
1839+
1840+ signal clicked()
1841+ signal profileImageClicked()
1842+
1843+ ListItem.Empty {
1844+ id: internalDelegate
1845+ anchors {
1846+ top: parent ? parent.top : undefined
1847+ left: parent ? parent.left : undefined
1848+ right: parent ? parent.right : undefined
1849+ }
1850+ height: bubble.height
1851+ showDivider: false
1852+ highlightWhenPressed: false
1853+
1854+ onClicked: messageDelegate.clicked()
1855+
1856+ Image {
1857+ id: image
1858+ anchors {
1859+ left: parent.left
1860+ leftMargin: source == "" ? 0 : units.gu(1)
1861+ bottom: parent.bottom
1862+ }
1863+
1864+ width: source == "" || source === undefined ? 0 : units.gu(5);
1865+ height: width
1866+ asynchronous: true
1867+ fillMode: Image.PreserveAspectCrop
1868+ source: senderImage
1869+
1870+ MouseArea {
1871+ anchors.fill: parent
1872+ onClicked: messageDelegate.profileImageClicked()
1873+ }
1874+ }
1875+
1876+ TelegramBubble {
1877+ id: bubble
1878+ outgoing: messageDelegate.outgoing
1879+ anchors {
1880+ top: parent.top
1881+ left: outgoing ? undefined: image.right
1882+ leftMargin: units.gu(1)
1883+ right: outgoing ? parent.right : undefined
1884+ rightMargin: units.gu(1)
1885+ }
1886+ height: messageContents.height + units.gu(2)
1887+ width: Math.max(messageLabel.width, senderLabel.width, messageStatusRow.width, messagePhoto.width) + units.gu(3)
1888+
1889+ Item {
1890+ id: messageContents
1891+ anchors {
1892+ top: parent.top
1893+ topMargin: units.gu(1)
1894+ left: parent.left
1895+ leftMargin: outgoing ? units.gu(1) : units.gu(2)
1896+ right: parent.right
1897+ rightMargin: units.gu(1.5)
1898+ }
1899+ height: childrenRect.height
1900+
1901+ Text {
1902+ id: senderLabel
1903+ anchors.top: parent.top
1904+ height: text === "" ? 0 : implicitHeight
1905+ font.pixelSize: FontUtils.sizeToPixels("small")
1906+ font.weight: Font.Normal
1907+ color: senderColor
1908+ text: senderName
1909+ }
1910+
1911+ Text {
1912+ id: messageLabel
1913+ anchors{
1914+ top: senderLabel.bottom
1915+ }
1916+ height: paintedHeight
1917+ width: Math.min(implicitWidth, 0.7 * internalDelegate.width)
1918+ wrapMode: Text.WrapAtWordBoundaryOrAnywhere
1919+ font.pixelSize: mediaType != TLMessageMedia.TypeMessageMediaEmpty ?
1920+ FontUtils.sizeToPixels("small") : FontUtils.sizeToPixels("medium")
1921+ font.weight: mediaType != TLMessageMedia.TypeMessageMediaEmpty ?
1922+ Font.DemiBold : Font.Normal
1923+ color: textColor
1924+ text: parseText(message)
1925+ onLinkActivated: Qt.openUrlExternally(link)
1926+
1927+ // Taken from messaging-app
1928+ function parseText(text) {
1929+ var phoneExp = /(\+?([0-9]+[ ]?)?\(?([0-9]+)\)?[-. ]?([0-9]+)[-. ]?([0-9]+)[-. ]?([0-9]+))/img;
1930+ // remove html tags
1931+ text = text.replace(/</g,'&lt;').replace(/>/g,'<tt>&gt;</tt>');
1932+ // replace line breaks
1933+ text = text.replace(/(\n)+/g, '<br />');
1934+ // check for links
1935+ var htmlText = BaLinkify.linkify(text);
1936+ if (htmlText !== text) {
1937+ return htmlText
1938+ }
1939+ // linkify phone numbers if no web links were found
1940+ return text.replace(phoneExp, '<a href="tel:///$1">$1</a>');
1941+ }
1942+ }
1943+
1944+ Image {
1945+ id: messagePhoto
1946+
1947+ anchors{
1948+ horizontalCenter: parent.horizontalCenter
1949+ top: senderLabel.bottom
1950+ }
1951+ asynchronous: true
1952+ visible: source !== ""
1953+ fillMode: Image.PreserveAspectFit
1954+ sourceSize.width: 0.6 * internalDelegate.width
1955+ sourceSize.height: 0.6 * internalDelegate.width
1956+ source: {
1957+ console.log("messagePhoto source: " + thumbnail);
1958+ return Qt.resolvedUrl(thumbnail);
1959+ }
1960+
1961+ onStatusChanged: {
1962+ if (status === Image.Error) {
1963+ source = "image://theme/image-missing"
1964+ width = 128
1965+ height = 128
1966+ }
1967+ }
1968+
1969+ MouseArea {
1970+ anchors.fill: parent
1971+ onClicked: {
1972+ var properties = { "previewSource": parent.source };
1973+ pageStack.push(previewPage, properties);
1974+ }
1975+ }
1976+ }
1977+
1978+ Row {
1979+ id: messageStatusRow
1980+
1981+ spacing: units.gu(0.5)
1982+
1983+ anchors {
1984+ top: messagePhoto.source != "" ? messagePhoto.bottom : messageLabel.bottom
1985+ right: parent.right
1986+ }
1987+
1988+ Text {
1989+ id: timeLabel
1990+ font.weight: Font.DemiBold
1991+ font.pixelSize: FontUtils.sizeToPixels("x-small")
1992+ color: outgoing ? Color.dark_green : Color.grey
1993+ text: time
1994+ }
1995+
1996+ Image {
1997+ id: messageSentStatus
1998+ visible: !sent
1999+ height: units.gu(1.4)
2000+ width: height
2001+ anchors.verticalCenter: timeLabel.verticalCenter
2002+ source: sent ? "" : Qt.resolvedUrl("../images/dialog_clock_w.png")
2003+ }
2004+ }
2005+ }
2006+ }
2007+ }
2008+}
2009
2010=== added file 'components/TelegramDialogsListItem.qml'
2011--- components/TelegramDialogsListItem.qml 1970-01-01 00:00:00 +0000
2012+++ components/TelegramDialogsListItem.qml 2014-10-11 18:44:23 +0000
2013@@ -0,0 +1,216 @@
2014+import QtQuick 2.0
2015+import Ubuntu.Components 1.1
2016+import Ubuntu.Components.ListItems 1.0 as ListItem
2017+import "TelegramColors.js" as TelegramColors
2018+
2019+MouseArea {
2020+ property alias image: image.source
2021+ property alias title: title.text
2022+ property alias sender: sender.text
2023+ property alias subtitle: subtitle.text
2024+ property alias unread: unread.text
2025+ property alias time: time.text
2026+ property bool isGroup: false
2027+ property bool isMedia: false
2028+ property bool isAction: false
2029+ property int delivery: 0
2030+
2031+ readonly property int delivery_none: 0
2032+ readonly property int delivery_sent: 1
2033+ readonly property int delivery_read: 2
2034+
2035+ id: listitem
2036+ width: parent.width
2037+ height: units.gu(8)
2038+
2039+ Rectangle {
2040+ id: background
2041+ anchors.fill: parent
2042+ color: listitem.pressed ? TelegramColors.list_pressed : TelegramColors.white
2043+ }
2044+
2045+ UbuntuShape {
2046+ id: imageShape
2047+ anchors {
2048+ top: parent.top
2049+ topMargin: units.dp(4)
2050+ left: parent.left
2051+ leftMargin: units.gu(1)
2052+ bottom: divider.top
2053+ bottomMargin: units.dp(4)
2054+ rightMargin: units.gu(1)
2055+ }
2056+ width: height
2057+
2058+ image: Image {
2059+ id: image
2060+ anchors.fill: parent
2061+ antialiasing: true
2062+ asynchronous: true
2063+ fillMode: Image.PreserveAspectFit
2064+ }
2065+ }
2066+
2067+ Image {
2068+ id: grouplistIndicator
2069+ anchors {
2070+ top: parent.top
2071+ left: imageShape.right
2072+
2073+ topMargin: units.gu(1.5)
2074+ leftMargin: units.gu(1)
2075+ rightMargin: units.gu(1)
2076+ }
2077+ width: visible ? units.gu(3) : 0
2078+ fillMode: Image.PreserveAspectFit
2079+
2080+ source: Qt.resolvedUrl("../images/grouplist.png")
2081+ visible: isGroup
2082+ }
2083+
2084+ Text {
2085+ id: time
2086+ anchors {
2087+ top: parent.top
2088+ right: parent.right
2089+
2090+ margins: units.dp(4)
2091+ rightMargin: units.gu(1)
2092+ }
2093+ height: parent.height/2
2094+ horizontalAlignment: Text.AlignRight
2095+ verticalAlignment: Text.AlignVCenter
2096+
2097+ color: TelegramColors.grey
2098+ text: "Wed"
2099+ }
2100+
2101+ Rectangle {
2102+ id: unreadBox
2103+ anchors {
2104+ right: time.right
2105+ verticalCenter: subtitle.verticalCenter
2106+ }
2107+ width: Math.max(units.gu(2.8), unread.width + units.gu(1))
2108+ height: units.gu(2.5)
2109+ radius: 2
2110+
2111+ color: TelegramColors.unread_green
2112+ visible: unread.text != "" && unread.text != "0"
2113+
2114+ Text {
2115+ id: unread
2116+ anchors {
2117+ centerIn: parent
2118+ topMargin: units.dp(4)
2119+ rightMargin: time.anchors.rightMargin
2120+ leftMargin: time.anchors.leftMargin
2121+ }
2122+ horizontalAlignment: TextInput.AlignHCenter
2123+ verticalAlignment: TextInput.AlignVCenter
2124+
2125+ font.weight: Font.DemiBold
2126+ font.pixelSize: FontUtils.sizeToPixels("small")
2127+ color: TelegramColors.white
2128+ text: "6"
2129+ }
2130+ }
2131+
2132+ Image {
2133+ id: sentIndicator
2134+ anchors {
2135+ verticalCenter: time.verticalCenter
2136+ right: time.left
2137+ topMargin: time.anchors.topMargin
2138+ rightMargin: units.dp(8)
2139+ }
2140+ width: units.gu(2)
2141+ height: width
2142+ z: 1
2143+ fillMode: Image.PreserveAspectFit
2144+
2145+ source: (delivery >= delivery_sent) ? Qt.resolvedUrl("../images/dialogs_check.png") : ""
2146+ }
2147+
2148+ Image {
2149+ id: deliveredIndicator
2150+ anchors {
2151+ verticalCenter: time.verticalCenter
2152+ right: time.left
2153+ topMargin: time.anchors.topMargin
2154+ rightMargin: sentIndicator.anchors.rightMargin - units.dp(5)
2155+ }
2156+ width: units.gu(2)
2157+ height: width
2158+ z: 2
2159+ fillMode: Image.PreserveAspectFit
2160+
2161+ source: (delivery == delivery_read) ? Qt.resolvedUrl("../images/dialogs_halfcheck.png") : ""
2162+ }
2163+
2164+ Text {
2165+ id: title
2166+ anchors {
2167+ top: parent.top
2168+ left: grouplistIndicator.right
2169+ leftMargin: units.dp(4)
2170+ bottom: time.bottom
2171+ right: sentIndicator.left
2172+ }
2173+ verticalAlignment: TextInput.AlignVCenter
2174+
2175+ font.pixelSize: FontUtils.sizeToPixels("large")
2176+ font.weight: Font.DemiBold
2177+ color: TelegramColors.black
2178+ elide: Text.ElideRight
2179+ text: "Telegram"
2180+ }
2181+
2182+ Text {
2183+ id: sender
2184+ anchors {
2185+ top: title.bottom
2186+ left: isGroup ? imageShape.right : title.left
2187+ leftMargin: isGroup ? units.gu(1) : 0
2188+ bottom: parent.bottom
2189+ bottomMargin: units.dp(4)
2190+ }
2191+ verticalAlignment: TextInput.AlignVCenter
2192+ visible: !isAction
2193+
2194+ font.pixelSize: FontUtils.sizeToPixels("medium")
2195+ color: TelegramColors.dark_blue
2196+ text: "Sender"
2197+ }
2198+
2199+ Text {
2200+ id: subtitle
2201+ anchors {
2202+ top: title.bottom
2203+ left: sender.text ? sender.right : title.left
2204+ leftMargin: 0
2205+ bottom: parent.bottom
2206+ bottomMargin: units.dp(4)
2207+ right: unreadBox.left
2208+ rightMargin: units.dp(4)
2209+ }
2210+ horizontalAlignment: TextInput.AlignLeft
2211+ verticalAlignment: TextInput.AlignVCenter
2212+
2213+ font.pixelSize: FontUtils.sizeToPixels("medium")
2214+ color: isMedia || isAction ? TelegramColors.dark_blue : TelegramColors.grey
2215+ elide: Text.ElideRight
2216+ text: "This is a test message."
2217+ }
2218+
2219+ ListItem.ThinDivider {
2220+ id: divider
2221+ anchors {
2222+ bottom: parent.bottom
2223+ left: parent.left
2224+ leftMargin: units.gu(1)
2225+ right: parent.right
2226+ rightMargin: units.gu(1)
2227+ }
2228+ }
2229+}
2230
2231=== added file 'components/TelegramHeader.qml'
2232--- components/TelegramHeader.qml 1970-01-01 00:00:00 +0000
2233+++ components/TelegramHeader.qml 2014-10-11 18:44:23 +0000
2234@@ -0,0 +1,79 @@
2235+import QtQuick 2.0
2236+
2237+// This component is intented for use in Ubuntu Header content.
2238+Item {
2239+ property alias title: titleText.text
2240+ property alias subtitle: subtitleText.text
2241+ property alias image: headerImage.source
2242+
2243+ property bool isConnecting: false
2244+
2245+ id: header
2246+ height: parent.height
2247+
2248+ Image {
2249+ id: headerImage
2250+ width: height
2251+ height: parent.height/2
2252+ anchors {
2253+ left: parent.left
2254+ verticalCenter: parent.verticalCenter
2255+ }
2256+ source: Qt.resolvedUrl("../images/ic_ab_logo.png")
2257+ RotationAnimation {
2258+ id: connectingAnimation
2259+ target: headerImage
2260+ direction: RotationAnimation.Clockwise
2261+ from: 0
2262+ to: 359
2263+ loops: Animation.Infinite
2264+ duration: 5000
2265+ alwaysRunToEnd: false
2266+ running: isConnecting
2267+
2268+ onRunningChanged: {
2269+ if (!running) {
2270+ connectingAnimation.stop();
2271+ headerImage.rotation = 0;
2272+ }
2273+ }
2274+ }
2275+ }
2276+
2277+ TelegramLabel {
2278+ id: titleText
2279+ // We need fixed width. Otherwise, we overflow action icons.
2280+ width: Math.min(implicitWidth, parent.width - headerImage.width - anchors.leftMargin)
2281+ anchors {
2282+ top: parent.top
2283+ topMargin: units.gu(1)
2284+ left: headerImage.right
2285+ leftMargin: units.gu(1)
2286+
2287+ verticalCenter: subtitleText.visible ? undefined : parent.verticalCenter
2288+ }
2289+ verticalAlignment: Text.AlignVCenter
2290+ height: subtitleText.visible ? parent.height / 2 : implicitHeight
2291+
2292+ font.pixelSize: FontUtils.sizeToPixels("large")
2293+ elide: Text.ElideRight
2294+ text: isConnecting ? i18n.tr("Connecting...") : i18n.tr("Telegram")
2295+ }
2296+
2297+ Text {
2298+ id: subtitleText
2299+ width: Math.min(implicitWidth, parent.width - headerImage.width - anchors.leftMargin)
2300+ anchors {
2301+ left: headerImage.right
2302+ leftMargin: units.gu(1)
2303+ bottom: parent.bottom
2304+ bottomMargin: units.gu(0.5)
2305+ }
2306+ verticalAlignment: Text.AlignVCenter
2307+ height: parent.height / 2
2308+ visible: text.length > 0
2309+
2310+ font.pixelSize: FontUtils.sizeToPixels("small")
2311+ elide: Text.ElideRight
2312+ }
2313+}
2314
2315=== added file 'components/TelegramLabel.qml'
2316--- components/TelegramLabel.qml 1970-01-01 00:00:00 +0000
2317+++ components/TelegramLabel.qml 2014-10-11 18:44:23 +0000
2318@@ -0,0 +1,10 @@
2319+import QtQuick 2.0
2320+import "../components"
2321+import "TelegramColors.js" as TelegramColors
2322+
2323+Text {
2324+ verticalAlignment: TextInput.AlignVCenter
2325+ horizontalAlignment: TextInput.AlignHCenter
2326+
2327+ color: TelegramColors.grey
2328+}
2329
2330=== added file 'components/TelegramPage.qml'
2331--- components/TelegramPage.qml 1970-01-01 00:00:00 +0000
2332+++ components/TelegramPage.qml 2014-10-11 18:44:23 +0000
2333@@ -0,0 +1,100 @@
2334+import QtQuick 2.0
2335+import Ubuntu.Components 1.1
2336+import Ubuntu.Connectivity 1.0
2337+import "TelegramColors.js" as TelegramColors
2338+
2339+Page {
2340+ id: root
2341+
2342+ property bool isSearching: false
2343+ property bool isOnline: NetworkingStatus.online
2344+ property bool isConnected: onlineIndicationOnly
2345+ ? isOnline
2346+ : isOnline && telegramClient.connected
2347+ property bool onlineIndicationOnly: false
2348+
2349+ property alias title: header.title
2350+ property alias subtitle: header.subtitle
2351+ property alias body: body.children
2352+ property alias searchTerm: searchField.text
2353+ property alias busy: activityIndicator.running
2354+
2355+ TelegramHeader {
2356+ id: header
2357+ isConnecting: !root.isConnected
2358+ visible: !isSearching
2359+ width: parent ? parent.width - units.gu(2) : undefined
2360+ }
2361+
2362+ TextField {
2363+ id: searchField
2364+ visible: isSearching
2365+ width: header.width
2366+ inputMethodHints: Qt.ImhNoPredictiveText
2367+
2368+ onTextChanged: {
2369+ if (typeof onSearchTermChanged === 'function') {
2370+ onSearchTermChanged(text);
2371+ }
2372+ }
2373+ }
2374+
2375+ head {
2376+ id: head
2377+ contents: isSearching ? searchField : header
2378+
2379+ backAction: Action {
2380+ id: backAction
2381+ iconName: "back"
2382+ onTriggered: {
2383+ if (isSearching) {
2384+ searchFinished();
2385+ return;
2386+ }
2387+ pageStack.pop();
2388+ if (typeof onBackPressed === 'function') {
2389+ onBackPressed();
2390+ }
2391+ }
2392+ }
2393+ }
2394+
2395+ Rectangle {
2396+ id: body
2397+ anchors.fill: parent
2398+ // Due to some fancy Page behavior, in fact,
2399+ // this doesn't end up as white anyway..
2400+ color: TelegramColors.page_background
2401+ }
2402+
2403+ ActivityIndicator {
2404+ id: activityIndicator
2405+ anchors.centerIn: parent
2406+ z: 101
2407+ }
2408+
2409+ Rectangle {
2410+ id: activityBackground
2411+ anchors.fill: parent
2412+ z: 100
2413+ color: "#44000000"
2414+ visible: activityIndicator.running
2415+ MouseArea {
2416+ anchors.fill: parent
2417+ preventStealing: true
2418+ enabled: activityIndicator.running
2419+ }
2420+ }
2421+
2422+ function searchPressed() {
2423+ isSearching = true;
2424+ searchField.forceActiveFocus();
2425+ }
2426+
2427+ function searchFinished() {
2428+ if (!isSearching) return;
2429+
2430+ isSearching = false;
2431+ searchField.text = "";
2432+ }
2433+}
2434
2435=== added file 'components/TelegramSection.qml'
2436--- components/TelegramSection.qml 1970-01-01 00:00:00 +0000
2437+++ components/TelegramSection.qml 2014-10-11 18:44:23 +0000
2438@@ -0,0 +1,29 @@
2439+import QtQuick 2.0
2440+import Ubuntu.Components 0.1
2441+import "TelegramColors.js" as Color
2442+
2443+Item {
2444+ anchors.margins: units.gu(1)
2445+
2446+ width: parent.width
2447+ height: childrenRect.height + units.gu(1)
2448+
2449+ Rectangle {
2450+ anchors.horizontalCenter: parent.horizontalCenter
2451+ width: sectionLabel.width + units.gu(2)
2452+ height: sectionLabel.height + units.gu(1)
2453+
2454+ color: Color.chat_section
2455+ radius: 3
2456+
2457+ Text {
2458+ id: sectionLabel
2459+ anchors.centerIn: parent
2460+
2461+ color: Color.white
2462+ font.weight: Font.DemiBold
2463+ font.pixelSize: FontUtils.sizeToPixels("medium")
2464+ text: section
2465+ }
2466+ }
2467+}
2468
2469=== added file 'components/TgButton.qml'
2470--- components/TgButton.qml 1970-01-01 00:00:00 +0000
2471+++ components/TgButton.qml 2014-10-11 18:44:23 +0000
2472@@ -0,0 +1,10 @@
2473+import QtQuick 2.0
2474+import Ubuntu.Components 0.1
2475+
2476+Button {
2477+ anchors{
2478+ left: parent.left
2479+ right: parent.right
2480+ }
2481+ text: i18n.tr("Next")
2482+}
2483
2484=== added file 'components/TgLabel.qml'
2485--- components/TgLabel.qml 1970-01-01 00:00:00 +0000
2486+++ components/TgLabel.qml 2014-10-11 18:44:23 +0000
2487@@ -0,0 +1,11 @@
2488+import QtQuick 2.0
2489+import Ubuntu.Components 0.1
2490+
2491+Label {
2492+ anchors{
2493+ left: parent.left
2494+ right: parent.right
2495+ }
2496+ horizontalAlignment: TextInput.AlignHCenter
2497+ verticalAlignment: TextInput.AlignVCenter
2498+}
2499
2500=== added file 'components/TgTextField.qml'
2501--- components/TgTextField.qml 1970-01-01 00:00:00 +0000
2502+++ components/TgTextField.qml 2014-10-11 18:44:23 +0000
2503@@ -0,0 +1,10 @@
2504+import QtQuick 2.0
2505+import Ubuntu.Components 0.1
2506+
2507+TextField {
2508+ anchors{
2509+ left: parent.left
2510+ right: parent.right
2511+ }
2512+ horizontalAlignment: TextInput.AlignHCenter
2513+}
2514
2515=== added file 'components/country_data.js'
2516--- components/country_data.js 1970-01-01 00:00:00 +0000
2517+++ components/country_data.js 2014-10-11 18:44:23 +0000
2518@@ -0,0 +1,6 @@
2519+var name_to_tel = {"China, Republic of (Taiwan)": "886", "Bosnia and Herzegovina": "387", "Slovakia": "421", "Somaliland": "252", "Trinidad and Tobago": "-867", "San Marino": "378", "Jordan": "962", "Cambodia": "855", "Norway": "47", "Burundi": "257", "Aland": "340", "Syria": "963", "Cook Islands": "682", "Malaysia": "60", "Egypt": "20", "Guyana": "592", "Estonia": "372", "Rwanda": "250", "Lebanon": "961", "Eritrea": "291", "Benin": "229", "France": "33", "Bhutan": "975", "Mozambique": "258", "Saint Martin": "590", "Nigeria": "234", "Croatia": "385", "Dominica": "-766", "Japan": "81", "Colombia": "57", "Canada": "1", "South Africa": "27", "Pakistan": "92", "Solomon Islands": "677", "Paraguay": "595", "Comoros": "269", "Macau": "853", "Bolivia": "591", "Belgium": "32", "Botswana": "267", "Anguilla": "-263", "Uzbekistan": "998", "Niger": "227", "New Caledonia": "687", "Israel": "972", "Congo, (Congo \u0096 Brazzaville)": "242", "Chile": "56", "Slovenia": "386", "Sweden": "46", "Monaco": "377", "Niue": "683", "Kuwait": "965", "Luxembourg": "352", "Barbados": "-245", "Mauritania": "222", "Togo": "228", "Peru": "51", "Thailand": "66", "Equatorial Guinea": "240", "Qatar": "974", "Montenegro": "382", "Australia": "61", "Grenada": "-472", "Suriname": "597", "Switzerland": "41", "Aruba": "297", "Azerbaijan": "994", "Venezuela": "58", "Bahamas, The": "-241", "Samoa": "685", "Djibouti": "253", "Singapore": "65", "Kiribati": "686", "American Samoa": "-683", "Hungary": "36", "Korea, South": "82", "Cote d'Ivoire (Ivory Coast)": "225", "Guatemala": "502", "Greece": "30", "Common Name": "ITU-T Telephone Code", "Vatican City": "379", "Zambia": "260", "Kazakhstan": "7", "Argentina": "54", "Belize": "501", "Chad": "235", "Guinea": "224", "Tonga": "676", "Poland": "48", "Myanmar (Burma)": "95", "Netherlands Antilles": "599", "Dominican Republic": "+1-809 and 1-829", "Saint Vincent and the Grenadines": "-783", "Gibraltar": "350", "Andorra": "376", "Cayman Islands": "-344", "Mauritius": "230", "Ascension": "247", "Cameroon": "237", "Fiji": "679", "Puerto Rico": "+1-787 and 1-939", "Angola": "244", "Maldives": "960", "Haiti": "509", "Saint Helena": "290", "Cuba": "53", "China, People's Republic of": "86", "Uganda": "256", "Mexico": "52", "Nagorno-Karabakh": "277", "Sao Tome and Principe": "239", "Mongolia": "976", "Saint Pierre and Miquelon": "508", "Korea, North": "850", "Uruguay": "598", "Cocos (Keeling) Islands": "61", "El Salvador": "503", "Bermuda": "-440", "Somalia": "252", "Ghana": "233", "Libya": "218", "Northern Mariana Islands": "-669", "Vietnam": "84", "Mayotte": "262", "Marshall Islands": "692", "Greenland": "299", "Morocco": "212", "Vanuatu": "678", "Liberia": "231", "Isle of Man": "44", "Palau": "680", "Martinique": "596", "Saint Kitts and Nevis": "-868", "Panama": "507", "Laos": "856", "Namibia": "264", "British Virgin Islands": "-283", "Kyrgyzstan": "996", "Kenya": "254", "Tokelau": "690", "Cape Verde": "238", "Sudan": "249", "Norfolk Island": "672", "French Guiana": "594", "Turkey": "90", "Gambia, The": "220", "Moldova": "373", "Italy": "39", "Nicaragua": "505", "Costa Rica": "506", "Lesotho": "266", "Falkland Islands (Islas Malvinas)": "500", "Guam": "-670", "Sierra Leone": "232", "Oman": "968", "Iceland": "354", "Brunei": "673", "Turkmenistan": "993", "Philippines": "63", "Ethiopia": "251", "India": "91", "Romania": "40", "Malawi": "265", "Micronesia": "691", "Czech Republic": "420", "Spain": "34", "South Ossetia": "995", "Timor-Leste (East Timor)": "670", "Abkhazia": "995", "Armenia": "374", "Madagascar": "261", "Serbia": "381", "Iran": "98", "British Indian Ocean Territory": "246", "Brazil": "55", "United Kingdom": "44", "Hong Kong": "852", "Ecuador": "593", "Lithuania": "370", "Pridnestrovie (Transnistria)": "-160", "Belarus": "375", "Yemen": "967", "Gabon": "241", "U.S. Virgin Islands": "-339", "Wallis and Futuna": "681", "Jersey": "44", "Burkina Faso": "226", "Christmas Island": "61", "United Arab Emirates": "971", "Indonesia": "62", "Cyprus": "357", "Papua New Guinea": "675", "Latvia": "371", "Afghanistan": "93", "Senegal": "221", "Reunion": "262", "Russia": "7", "Tajikistan": "992", "Iraq": "964", "Georgia": "995", "Saint Barthelemy": "590", "Saudi Arabia": "966", "Austria": "43", "Honduras": "504", "Swaziland": "268", "Albania": "355", "Nepal": "977", "French Polynesia": "689", "Finland": "358", "Jamaica": "-875", "Central African Republic": "236", "Denmark": "45", "Mali": "223", "Tunisia": "216", "Germany": "49", "Congo, (Congo \u0096 Kinshasa)": "243", "Faroe Islands": "298", "Sri Lanka": "94", "Seychelles": "248", "Tristan da Cunha": "290", "Turks and Caicos Islands": "-648", "Tanzania": "255", "Zimbabwe": "263", "United States": "1", "Liechtenstein": "423", "Nauru": "674", "Guernsey": "44", "Northern Cyprus": "-302", "Bulgaria": "359", "Malta": "356", "Guadeloupe": "590", "Montserrat": "-663", "Portugal": "351", "Ukraine": "380", "Macedonia": "389", "Ireland": "353", "Svalbard": "47", "Netherlands": "31", "Antigua and Barbuda": "-267", "New Zealand": "64", "Bahrain": "973", "Saint Lucia": "-757", "Guinea-Bissau": "245", "Algeria": "213", "Tuvalu": "688", "Bangladesh": "880"};
2520+var name_to_iso = {"China, Republic of (Taiwan)": "TW", "Bosnia and Herzegovina": "BA", "Slovakia": "SK", "Somaliland": "SO", "Trinidad and Tobago": "TT", "San Marino": "SM", "Jordan": "JO", "Cambodia": "KH", "Norway": "NO", "Burundi": "BI", "Aland": "AX", "Syria": "SY", "Cook Islands": "CK", "Malaysia": "MY", "Egypt": "EG", "Guyana": "GY", "Estonia": "EE", "Rwanda": "RW", "Lebanon": "LB", "Eritrea": "ER", "Benin": "BJ", "France": "FR", "Bhutan": "BT", "Mozambique": "MZ", "Saint Martin": "GP", "Nigeria": "NG", "Croatia": "HR", "Dominica": "DM", "Japan": "JP", "Colombia": "CO", "Canada": "CA", "South Africa": "ZA", "Pakistan": "PK", "Solomon Islands": "SB", "Paraguay": "PY", "Comoros": "KM", "Macau": "MO", "Bolivia": "BO", "Belgium": "BE", "Botswana": "BW", "Anguilla": "AI", "Uzbekistan": "UZ", "Niger": "NE", "New Caledonia": "NC", "Israel": "IL", "Congo, (Congo \u0096 Brazzaville)": "CG", "Chile": "CL", "Slovenia": "SI", "Sweden": "SE", "Monaco": "MC", "Niue": "NU", "Kuwait": "KW", "Luxembourg": "LU", "Barbados": "BB", "Mauritania": "MR", "Togo": "TG", "Peru": "PE", "Thailand": "TH", "Equatorial Guinea": "GQ", "Qatar": "QA", "Montenegro": "ME", "Australia": "AU", "Grenada": "GD", "Suriname": "SR", "Switzerland": "CH", "Aruba": "AW", "Azerbaijan": "AZ", "Venezuela": "VE", "Bahamas, The": "BS", "Samoa": "WS", "Djibouti": "DJ", "Singapore": "SG", "Kiribati": "KI", "American Samoa": "AS", "Hungary": "HU", "Korea, South": "KR", "Cote d'Ivoire (Ivory Coast)": "CI", "Guatemala": "GT", "Greece": "GR", "Common Name": "ISO 3166-1 2 Letter Code", "Vatican City": "VA", "Zambia": "ZM", "Kazakhstan": "KZ", "Argentina": "AR", "Belize": "BZ", "Chad": "TD", "Guinea": "GN", "Tonga": "TO", "Poland": "PL", "Myanmar (Burma)": "MM", "Netherlands Antilles": "AN", "Dominican Republic": "DO", "Saint Vincent and the Grenadines": "VC", "Gibraltar": "GI", "Andorra": "AD", "Cayman Islands": "KY", "Mauritius": "MU", "Ascension": "AC", "Cameroon": "CM", "Fiji": "FJ", "Puerto Rico": "PR", "Angola": "AO", "Maldives": "MV", "Haiti": "HT", "Saint Helena": "SH", "Cuba": "CU", "China, People's Republic of": "CN", "Uganda": "UG", "Mexico": "MX", "Nagorno-Karabakh": "AZ", "Sao Tome and Principe": "ST", "Mongolia": "MN", "Saint Pierre and Miquelon": "PM", "Korea, North": "KP", "Uruguay": "UY", "Cocos (Keeling) Islands": "CC", "El Salvador": "SV", "Bermuda": "BM", "Somalia": "SO", "Ghana": "GH", "Libya": "LY", "Northern Mariana Islands": "MP", "Vietnam": "VN", "Mayotte": "YT", "Marshall Islands": "MH", "Greenland": "GL", "Morocco": "MA", "Vanuatu": "VU", "Liberia": "LR", "Isle of Man": "IM", "Palau": "PW", "Martinique": "MQ", "Saint Kitts and Nevis": "KN", "Panama": "PA", "Laos": "LA", "Namibia": "NA", "British Virgin Islands": "VG", "Kyrgyzstan": "KG", "Kenya": "KE", "Tokelau": "TK", "Cape Verde": "CV", "Sudan": "SD", "Norfolk Island": "NF", "French Guiana": "GF", "Turkey": "TR", "Gambia, The": "GM", "Moldova": "MD", "Italy": "IT", "Nicaragua": "NI", "Costa Rica": "CR", "Lesotho": "LS", "Falkland Islands (Islas Malvinas)": "FK", "Guam": "GU", "Sierra Leone": "SL", "Oman": "OM", "Iceland": "IS", "Brunei": "BN", "Turkmenistan": "TM", "Philippines": "PH", "Ethiopia": "ET", "India": "IN", "Romania": "RO", "Malawi": "MW", "Micronesia": "FM", "Czech Republic": "CZ", "Spain": "ES", "South Ossetia": "GE", "Timor-Leste (East Timor)": "TL", "Abkhazia": "GE", "Armenia": "AM", "Madagascar": "MG", "Serbia": "RS", "Iran": "IR", "British Indian Ocean Territory": "IO", "Brazil": "BR", "United Kingdom": "GB", "Hong Kong": "HK", "Ecuador": "EC", "Lithuania": "LT", "Pridnestrovie (Transnistria)": "MD", "Belarus": "BY", "Yemen": "YE", "Gabon": "GA", "U.S. Virgin Islands": "VI", "Wallis and Futuna": "WF", "Jersey": "JE", "Burkina Faso": "BF", "Christmas Island": "CX", "United Arab Emirates": "AE", "Indonesia": "ID", "Cyprus": "CY", "Papua New Guinea": "PG", "Latvia": "LV", "Afghanistan": "AF", "Senegal": "SN", "Reunion": "RE", "Russia": "RU", "Tajikistan": "TJ", "Iraq": "IQ", "Georgia": "GE", "Saint Barthelemy": "GP", "Saudi Arabia": "SA", "Austria": "AT", "Honduras": "HN", "Swaziland": "SZ", "Albania": "AL", "Nepal": "NP", "French Polynesia": "PF", "Finland": "FI", "Jamaica": "JM", "Central African Republic": "CF", "Denmark": "DK", "Mali": "ML", "Tunisia": "TN", "Germany": "DE", "Congo, (Congo \u0096 Kinshasa)": "CD", "Faroe Islands": "FO", "Sri Lanka": "LK", "Seychelles": "SC", "Tristan da Cunha": "TA", "Turks and Caicos Islands": "TC", "Tanzania": "TZ", "Zimbabwe": "ZW", "United States": "US", "Liechtenstein": "LI", "Nauru": "NR", "Guernsey": "GG", "Northern Cyprus": "CY", "Bulgaria": "BG", "Malta": "MT", "Guadeloupe": "GP", "Montserrat": "MS", "Portugal": "PT", "Ukraine": "UA", "Macedonia": "MK", "Ireland": "IE", "Svalbard": "SJ", "Netherlands": "NL", "Antigua and Barbuda": "AG", "New Zealand": "NZ", "Bahrain": "BH", "Saint Lucia": "LC", "Guinea-Bissau": "GW", "Algeria": "DZ", "Tuvalu": "TV", "Bangladesh": "BD"};
2521+var iso_to_name = {"ET": "Ethiopia", "IR": "Iran", "SH": "Saint Helena", "LV": "Latvia", "CX": "Christmas Island", "TV": "Tuvalu", "SY": "Syria", "CN": "China, People's Republic of", "NL": "Netherlands", "MW": "Malawi", "RU": "Russia", "AI": "Anguilla", "AT": "Austria", "TR": "Turkey", "NF": "Norfolk Island", "PK": "Pakistan", "CZ": "Czech Republic", "BZ": "Belize", "HK": "Hong Kong", "CF": "Central African Republic", "PF": "French Polynesia", "KI": "Kiribati", "FI": "Finland", "GU": "Guam", "NE": "Niger", "BD": "Bangladesh", "ZA": "South Africa", "GL": "Greenland", "MG": "Madagascar", "NA": "Namibia", "YT": "Mayotte", "UY": "Uruguay", "SZ": "Swaziland", "GP": "Guadeloupe", "GI": "Gibraltar", "MZ": "Mozambique", "NC": "New Caledonia", "MD": "Pridnestrovie (Transnistria)", "IO": "British Indian Ocean Territory", "GR": "Greece", "HN": "Honduras", "ES": "Spain", "VI": "U.S. Virgin Islands", "DZ": "Algeria", "TH": "Thailand", "AU": "Australia", "BR": "Brazil", "BG": "Bulgaria", "BA": "Bosnia and Herzegovina", "MR": "Mauritania", "AW": "Aruba", "VC": "Saint Vincent and the Grenadines", "SK": "Slovakia", "GN": "Guinea", "ST": "Sao Tome and Principe", "JE": "Jersey", "NO": "Norway", "VE": "Venezuela", "IN": "India", "BJ": "Benin", "SJ": "Svalbard", "NZ": "New Zealand", "CU": "Cuba", "AL": "Albania", "LY": "Libya", "CO": "Colombia", "AD": "Andorra", "HT": "Haiti", "AR": "Argentina", "AN": "Netherlands Antilles", "AE": "United Arab Emirates", "KZ": "Kazakhstan", "DO": "Dominican Republic", "NU": "Niue", "LI": "Liechtenstein", "MT": "Malta", "AZ": "Nagorno-Karabakh", "LC": "Saint Lucia", "ZW": "Zimbabwe", "BE": "Belgium", "EC": "Ecuador", "KM": "Comoros", "MH": "Marshall Islands", "MN": "Mongolia", "SL": "Sierra Leone", "BM": "Bermuda", "ISO 3166-1 2 Letter Code": "Common Name", "CY": "Northern Cyprus", "PW": "Palau", "SG": "Singapore", "MO": "Macau", "ML": "Mali", "MM": "Myanmar (Burma)", "PY": "Paraguay", "GB": "United Kingdom", "DM": "Dominica", "YE": "Yemen", "RS": "Serbia", "FK": "Falkland Islands (Islas Malvinas)", "KE": "Kenya", "JO": "Jordan", "RE": "Reunion", "LB": "Lebanon", "MV": "Maldives", "ID": "Indonesia", "BS": "Bahamas, The", "PT": "Portugal", "CM": "Cameroon", "AS": "American Samoa", "BN": "Brunei", "SD": "Sudan", "BB": "Barbados", "PH": "Philippines", "LA": "Laos", "LU": "Luxembourg", "SA": "Saudi Arabia", "IT": "Italy", "TA": "Tristan da Cunha", "MY": "Malaysia", "KW": "Kuwait", "SR": "Suriname", "KR": "Korea, South", "TD": "Chad", "RW": "Rwanda", "TG": "Togo", "SM": "San Marino", "AX": "Aland", "FJ": "Fiji", "BT": "Bhutan", "ME": "Montenegro", "HR": "Croatia", "CA": "Canada", "IS": "Iceland", "GW": "Guinea-Bissau", "EG": "Egypt", "PL": "Poland", "TZ": "Tanzania", "BH": "Bahrain", "PE": "Peru", "IL": "Israel", "VA": "Vatican City", "MA": "Morocco", "US": "United States", "GQ": "Equatorial Guinea", "BI": "Burundi", "IM": "Isle of Man", "GG": "Guernsey", "CL": "Chile", "GA": "Gabon", "AM": "Armenia", "GF": "French Guiana", "DK": "Denmark", "KY": "Cayman Islands", "IQ": "Iraq", "FR": "France", "TK": "Tokelau", "WF": "Wallis and Futuna", "KH": "Cambodia", "TM": "Turkmenistan", "RO": "Romania", "DJ": "Djibouti", "TW": "China, Republic of (Taiwan)", "MQ": "Martinique", "MX": "Mexico", "BW": "Botswana", "NG": "Nigeria", "SO": "Somaliland", "NP": "Nepal", "TT": "Trinidad and Tobago", "FM": "Micronesia", "SV": "El Salvador", "JP": "Japan", "HU": "Hungary", "FO": "Faroe Islands", "TC": "Turks and Caicos Islands", "KP": "Korea, North", "AG": "Antigua and Barbuda", "AC": "Ascension", "CH": "Switzerland", "GY": "Guyana", "PM": "Saint Pierre and Miquelon", "BY": "Belarus", "BF": "Burkina Faso", "GE": "South Ossetia", "LR": "Liberia", "CK": "Cook Islands", "LK": "Sri Lanka", "PR": "Puerto Rico", "MK": "Macedonia", "IE": "Ireland", "MC": "Monaco", "TO": "Tonga", "SC": "Seychelles", "MS": "Montserrat", "KN": "Saint Kitts and Nevis", "EE": "Estonia", "SI": "Slovenia", "PG": "Papua New Guinea", "CI": "Cote d'Ivoire (Ivory Coast)", "UG": "Uganda", "CC": "Cocos (Keeling) Islands", "SN": "Senegal", "TN": "Tunisia", "DE": "Germany", "GT": "Guatemala", "UZ": "Uzbekistan", "CV": "Cape Verde", "MU": "Mauritius", "WS": "Samoa", "MP": "Northern Mariana Islands", "ER": "Eritrea", "UA": "Ukraine", "CG": "Congo, (Congo \u0096 Brazzaville)", "GM": "Gambia, The", "CR": "Costa Rica", "SB": "Solomon Islands", "VU": "Vanuatu", "AO": "Angola", "JM": "Jamaica", "LT": "Lithuania", "OM": "Oman", "LS": "Lesotho", "BO": "Bolivia", "KG": "Kyrgyzstan", "GH": "Ghana", "NI": "Nicaragua", "ZM": "Zambia", "QA": "Qatar", "PA": "Panama", "VN": "Vietnam", "GD": "Grenada", "NR": "Nauru", "SE": "Sweden", "AF": "Afghanistan", "TJ": "Tajikistan", "CD": "Congo, (Congo \u0096 Kinshasa)", "TL": "Timor-Leste (East Timor)", "VG": "British Virgin Islands"};
2522+var iso_to_tel = {"ET": "251", "IR": "98", "SH": "290", "LV": "371", "CX": "61", "TV": "688", "SY": "963", "CN": "86", "NL": "31", "MW": "265", "RU": "7", "AI": "-263", "AT": "43", "TR": "90", "NF": "672", "PK": "92", "CZ": "420", "BZ": "501", "HK": "852", "CF": "236", "PF": "689", "KI": "686", "FI": "358", "GU": "-670", "NE": "227", "BD": "880", "ZA": "27", "GL": "299", "MG": "261", "NA": "264", "YT": "262", "UY": "598", "SZ": "268", "GP": "590", "GI": "350", "MZ": "258", "NC": "687", "MD": "-160", "IO": "246", "GR": "30", "HN": "504", "ES": "34", "VI": "-339", "DZ": "213", "TH": "66", "AU": "61", "BR": "55", "BG": "359", "BA": "387", "MR": "222", "AW": "297", "VC": "-783", "SK": "421", "GN": "224", "ST": "239", "JE": "44", "NO": "47", "VE": "58", "IN": "91", "BJ": "229", "SJ": "47", "NZ": "64", "CU": "53", "AL": "355", "LY": "218", "CO": "57", "AD": "376", "HT": "509", "AR": "54", "AN": "599", "AE": "971", "KZ": "7", "DO": "+1-809 and 1-829", "NU": "683", "LI": "423", "MT": "356", "AZ": "277", "LC": "-757", "ZW": "263", "BE": "32", "EC": "593", "KM": "269", "MH": "692", "MN": "976", "SL": "232", "BM": "-440", "ISO 3166-1 2 Letter Code": "ITU-T Telephone Code", "CY": "-302", "PW": "680", "SG": "65", "MO": "853", "ML": "223", "MM": "95", "PY": "595", "GB": "44", "DM": "-766", "YE": "967", "RS": "381", "FK": "500", "KE": "254", "JO": "962", "RE": "262", "LB": "961", "MV": "960", "ID": "62", "BS": "-241", "PT": "351", "CM": "237", "AS": "-683", "BN": "673", "SD": "249", "BB": "-245", "PH": "63", "LA": "856", "LU": "352", "SA": "966", "IT": "39", "TA": "290", "MY": "60", "KW": "965", "SR": "597", "KR": "82", "TD": "235", "RW": "250", "TG": "228", "SM": "378", "AX": "340", "FJ": "679", "BT": "975", "ME": "382", "HR": "385", "CA": "1", "IS": "354", "GW": "245", "EG": "20", "PL": "48", "TZ": "255", "BH": "973", "PE": "51", "IL": "972", "VA": "379", "MA": "212", "US": "1", "GQ": "240", "BI": "257", "IM": "44", "GG": "44", "CL": "56", "GA": "241", "AM": "374", "GF": "594", "DK": "45", "KY": "-344", "IQ": "964", "FR": "33", "TK": "690", "WF": "681", "KH": "855", "TM": "993", "RO": "40", "DJ": "253", "TW": "886", "MQ": "596", "MX": "52", "BW": "267", "NG": "234", "SO": "252", "NP": "977", "TT": "-867", "FM": "691", "SV": "503", "JP": "81", "HU": "36", "FO": "298", "TC": "-648", "KP": "850", "AG": "-267", "AC": "247", "CH": "41", "GY": "592", "PM": "508", "BY": "375", "BF": "226", "GE": "995", "LR": "231", "CK": "682", "LK": "94", "PR": "+1-787 and 1-939", "MK": "389", "IE": "353", "MC": "377", "TO": "676", "SC": "248", "MS": "-663", "KN": "-868", "EE": "372", "SI": "386", "PG": "675", "CI": "225", "UG": "256", "CC": "61", "SN": "221", "TN": "216", "DE": "49", "GT": "502", "UZ": "998", "CV": "238", "MU": "230", "WS": "685", "MP": "-669", "ER": "291", "UA": "380", "CG": "242", "GM": "220", "CR": "506", "SB": "677", "VU": "678", "AO": "244", "JM": "-875", "LT": "370", "OM": "968", "LS": "266", "BO": "591", "KG": "996", "GH": "233", "NI": "505", "ZM": "260", "QA": "974", "PA": "507", "VN": "84", "GD": "-472", "NR": "674", "SE": "46", "AF": "93", "TJ": "992", "CD": "243", "TL": "670", "VG": "-283"};
2523+var tel_to_name = {"961": "Lebanon", "995": "South Ossetia", "-283": "British Virgin Islands", "386": "Slovenia", "ITU-T Telephone Code": "Common Name", "90": "Turkey", "216": "Tunisia", "40": "Romania", "421": "Slovakia", "+1-787 and 1-939": "Puerto Rico", "855": "Cambodia", "20": "Egypt", "267": "Botswana", "389": "Macedonia", "243": "Congo, (Congo \u0096 Kinshasa)", "241": "Gabon", "965": "Kuwait", "62": "Indonesia", "51": "Peru", "998": "Uzbekistan", "240": "Equatorial Guinea", "594": "French Guiana", "41": "Switzerland", "886": "China, Republic of (Taiwan)", "236": "Central African Republic", "298": "Faroe Islands", "94": "Sri Lanka", "-683": "American Samoa", "220": "Gambia, The", "-783": "Saint Vincent and the Grenadines", "371": "Latvia", "975": "Bhutan", "54": "Argentina", "-472": "Grenada", "258": "Mozambique", "599": "Netherlands Antilles", "-302": "Northern Cyprus", "55": "Brazil", "972": "Israel", "670": "Timor-Leste (East Timor)", "375": "Belarus", "971": "United Arab Emirates", "960": "Maldives", "-669": "Northern Mariana Islands", "32": "Belgium", "81": "Japan", "61": "Cocos (Keeling) Islands", "508": "Saint Pierre and Miquelon", "30": "Greece", "233": "Ghana", "340": "Aland", "245": "Guinea-Bissau", "-663": "Montserrat", "-160": "Pridnestrovie (Transnistria)", "252": "Somaliland", "229": "Benin", "503": "El Salvador", "596": "Martinique", "-263": "Anguilla", "385": "Croatia", "968": "Oman", "228": "Togo", "598": "Uruguay", "86": "China, People's Republic of", "593": "Ecuador", "-245": "Barbados", "-440": "Bermuda", "-867": "Trinidad and Tobago", "500": "Falkland Islands (Islas Malvinas)", "65": "Singapore", "688": "Tuvalu", "266": "Lesotho", "49": "Germany", "506": "Costa Rica", "377": "Monaco", "880": "Bangladesh", "504": "Honduras", "358": "Finland", "-648": "Turks and Caicos Islands", "98": "Iran", "996": "Kyrgyzstan", "60": "Malaysia", "963": "Syria", "689": "French Polynesia", "372": "Estonia", "-670": "Guam", "686": "Kiribati", "974": "Qatar", "852": "Hong Kong", "352": "Luxembourg", "48": "Poland", "381": "Serbia", "359": "Bulgaria", "690": "Tokelau", "268": "Swaziland", "226": "Burkina Faso", "82": "Korea, South", "64": "New Zealand", "675": "Papua New Guinea", "376": "Andorra", "502": "Guatemala", "681": "Wallis and Futuna", "354": "Iceland", "591": "Bolivia", "420": "Czech Republic", "221": "Senegal", "255": "Tanzania", "380": "Ukraine", "501": "Belize", "242": "Congo, (Congo \u0096 Brazzaville)", "682": "Cook Islands", "856": "Laos", "57": "Colombia", "261": "Madagascar", "595": "Paraguay", "218": "Libya", "692": "Marshall Islands", "379": "Vatican City", "677": "Solomon Islands", "222": "Mauritania", "232": "Sierra Leone", "370": "Lithuania", "853": "Macau", "850": "Korea, North", "247": "Ascension", "249": "Sudan", "-344": "Cayman Islands", "-339": "U.S. Virgin Islands", "973": "Bahrain", "251": "Ethiopia", "269": "Comoros", "238": "Cape Verde", "47": "Svalbard", "590": "Guadeloupe", "277": "Nagorno-Karabakh", "244": "Angola", "212": "Morocco", "976": "Mongolia", "223": "Mali", "246": "British Indian Ocean Territory", "505": "Nicaragua", "53": "Cuba", "378": "San Marino", "260": "Zambia", "231": "Liberia", "1": "United States", "351": "Portugal", "673": "Brunei", "678": "Vanuatu", "993": "Turkmenistan", "56": "Chile", "63": "Philippines", "45": "Denmark", "36": "Hungary", "-875": "Jamaica", "-241": "Bahamas, The", "687": "New Caledonia", "967": "Yemen", "685": "Samoa", "691": "Micronesia", "977": "Nepal", "290": "Tristan da Cunha", "7": "Russia", "234": "Nigeria", "683": "Niue", "353": "Ireland", "374": "Armenia", "597": "Suriname", "254": "Kenya", "265": "Malawi", "992": "Tajikistan", "46": "Sweden", "-757": "Saint Lucia", "299": "Greenland", "291": "Eritrea", "43": "Austria", "256": "Uganda", "66": "Thailand", "964": "Iraq", "84": "Vietnam", "264": "Namibia", "297": "Aruba", "58": "Venezuela", "93": "Afghanistan", "34": "Spain", "+1-809 and 1-829": "Dominican Republic", "-868": "Saint Kitts and Nevis", "237": "Cameroon", "52": "Mexico", "224": "Guinea", "350": "Gibraltar", "672": "Norfolk Island", "225": "Cote d'Ivoire (Ivory Coast)", "44": "United Kingdom", "507": "Panama", "253": "Djibouti", "257": "Burundi", "227": "Niger", "966": "Saudi Arabia", "680": "Palau", "423": "Liechtenstein", "31": "Netherlands", "679": "Fiji", "91": "India", "230": "Mauritius", "994": "Azerbaijan", "235": "Chad", "-267": "Antigua and Barbuda", "373": "Moldova", "962": "Jordan", "676": "Tonga", "213": "Algeria", "674": "Nauru", "-766": "Dominica", "248": "Seychelles", "382": "Montenegro", "95": "Myanmar (Burma)", "250": "Rwanda", "357": "Cyprus", "262": "Reunion", "39": "Italy", "263": "Zimbabwe", "592": "Guyana", "239": "Sao Tome and Principe", "92": "Pakistan", "355": "Albania", "387": "Bosnia and Herzegovina", "509": "Haiti", "33": "France", "356": "Malta", "27": "South Africa"};
2524+var tel_to_iso = {"961": "LB", "995": "GE", "-283": "VG", "386": "SI", "ITU-T Telephone Code": "ISO 3166-1 2 Letter Code", "90": "TR", "216": "TN", "40": "RO", "421": "SK", "+1-787 and 1-939": "PR", "855": "KH", "20": "EG", "267": "BW", "389": "MK", "243": "CD", "241": "GA", "965": "KW", "62": "ID", "51": "PE", "998": "UZ", "240": "GQ", "594": "GF", "41": "CH", "886": "TW", "236": "CF", "298": "FO", "94": "LK", "-683": "AS", "220": "GM", "-783": "VC", "371": "LV", "975": "BT", "54": "AR", "-472": "GD", "258": "MZ", "599": "AN", "-302": "CY", "55": "BR", "972": "IL", "670": "TL", "375": "BY", "971": "AE", "960": "MV", "-669": "MP", "32": "BE", "81": "JP", "61": "CC", "508": "PM", "30": "GR", "233": "GH", "340": "AX", "245": "GW", "-663": "MS", "-160": "MD", "252": "SO", "229": "BJ", "503": "SV", "596": "MQ", "-263": "AI", "385": "HR", "968": "OM", "228": "TG", "598": "UY", "86": "CN", "593": "EC", "-245": "BB", "-440": "BM", "-867": "TT", "500": "FK", "65": "SG", "688": "TV", "266": "LS", "49": "DE", "506": "CR", "377": "MC", "880": "BD", "504": "HN", "358": "FI", "-648": "TC", "98": "IR", "996": "KG", "60": "MY", "963": "SY", "689": "PF", "372": "EE", "-670": "GU", "686": "KI", "974": "QA", "852": "HK", "352": "LU", "48": "PL", "381": "RS", "359": "BG", "690": "TK", "268": "SZ", "226": "BF", "82": "KR", "64": "NZ", "675": "PG", "376": "AD", "502": "GT", "681": "WF", "354": "IS", "591": "BO", "420": "CZ", "221": "SN", "255": "TZ", "380": "UA", "501": "BZ", "242": "CG", "682": "CK", "856": "LA", "57": "CO", "261": "MG", "595": "PY", "218": "LY", "692": "MH", "379": "VA", "677": "SB", "222": "MR", "232": "SL", "370": "LT", "853": "MO", "850": "KP", "247": "AC", "249": "SD", "-344": "KY", "-339": "VI", "973": "BH", "251": "ET", "269": "KM", "238": "CV", "47": "SJ", "590": "GP", "277": "AZ", "244": "AO", "212": "MA", "976": "MN", "223": "ML", "246": "IO", "505": "NI", "53": "CU", "378": "SM", "260": "ZM", "231": "LR", "1": "US", "351": "PT", "673": "BN", "678": "VU", "993": "TM", "56": "CL", "63": "PH", "45": "DK", "36": "HU", "-875": "JM", "-241": "BS", "687": "NC", "967": "YE", "685": "WS", "691": "FM", "977": "NP", "290": "TA", "7": "RU", "234": "NG", "683": "NU", "353": "IE", "374": "AM", "597": "SR", "254": "KE", "265": "MW", "992": "TJ", "46": "SE", "-757": "LC", "299": "GL", "291": "ER", "43": "AT", "256": "UG", "66": "TH", "964": "IQ", "84": "VN", "264": "NA", "297": "AW", "58": "VE", "93": "AF", "34": "ES", "+1-809 and 1-829": "DO", "-868": "KN", "237": "CM", "52": "MX", "224": "GN", "350": "GI", "672": "NF", "225": "CI", "44": "GB", "507": "PA", "253": "DJ", "257": "BI", "227": "NE", "966": "SA", "680": "PW", "423": "LI", "31": "NL", "679": "FJ", "91": "IN", "230": "MU", "994": "AZ", "235": "TD", "-267": "AG", "373": "MD", "962": "JO", "676": "TO", "213": "DZ", "674": "NR", "-766": "DM", "248": "SC", "382": "ME", "95": "MM", "250": "RW", "357": "CY", "262": "RE", "39": "IT", "263": "ZW", "592": "GY", "239": "ST", "92": "PK", "355": "AL", "387": "BA", "509": "HT", "33": "FR", "356": "MT", "27": "ZA"}
2525\ No newline at end of file
2526
2527=== added file 'components/iso_3166_2_countries.csv'
2528--- components/iso_3166_2_countries.csv 1970-01-01 00:00:00 +0000
2529+++ components/iso_3166_2_countries.csv 2014-10-11 18:44:23 +0000
2530@@ -0,0 +1,269 @@
2531+Sort Order,Common Name,Formal Name,Type,Sub Type,Sovereignty,Capital,ISO 4217 Currency Code,ISO 4217 Currency Name,ITU-T Telephone Code,ISO 3166-1 2 Letter Code,ISO 3166-1 3 Letter Code,ISO 3166-1 Number,IANA Country Code TLD
2532+1,Afghanistan,Islamic State of Afghanistan,Independent State,,,Kabul,AFN,Afghani,93,AF,AFG,4,.af
2533+2,Albania,Republic of Albania,Independent State,,,Tirana,ALL,Lek,355,AL,ALB,8,.al
2534+3,Algeria,People's Democratic Republic of Algeria,Independent State,,,Algiers,DZD,Dinar,213,DZ,DZA,12,.dz
2535+4,Andorra,Principality of Andorra,Independent State,,,Andorra la Vella,EUR,Euro,376,AD,AND,20,.ad
2536+5,Angola,Republic of Angola,Independent State,,,Luanda,AOA,Kwanza,244,AO,AGO,24,.ao
2537+6,Antigua and Barbuda,,Independent State,,,Saint John's,XCD,Dollar,-267,AG,ATG,28,.ag
2538+7,Argentina,Argentine Republic,Independent State,,,Buenos Aires,ARS,Peso,54,AR,ARG,32,.ar
2539+8,Armenia,Republic of Armenia,Independent State,,,Yerevan,AMD,Dram,374,AM,ARM,51,.am
2540+9,Australia,Commonwealth of Australia,Independent State,,,Canberra,AUD,Dollar,61,AU,AUS,36,.au
2541+10,Austria,Republic of Austria,Independent State,,,Vienna,EUR,Euro,43,AT,AUT,40,.at
2542+11,Azerbaijan,Republic of Azerbaijan,Independent State,,,Baku,AZN,Manat,994,AZ,AZE,31,.az
2543+12,"Bahamas, The",Commonwealth of The Bahamas,Independent State,,,Nassau,BSD,Dollar,-241,BS,BHS,44,.bs
2544+13,Bahrain,Kingdom of Bahrain,Independent State,,,Manama,BHD,Dinar,973,BH,BHR,48,.bh
2545+14,Bangladesh,People's Republic of Bangladesh,Independent State,,,Dhaka,BDT,Taka,880,BD,BGD,50,.bd
2546+15,Barbados,,Independent State,,,Bridgetown,BBD,Dollar,-245,BB,BRB,52,.bb
2547+16,Belarus,Republic of Belarus,Independent State,,,Minsk,BYR,Ruble,375,BY,BLR,112,.by
2548+17,Belgium,Kingdom of Belgium,Independent State,,,Brussels,EUR,Euro,32,BE,BEL,56,.be
2549+18,Belize,,Independent State,,,Belmopan,BZD,Dollar,501,BZ,BLZ,84,.bz
2550+19,Benin,Republic of Benin,Independent State,,,Porto-Novo,XOF,Franc,229,BJ,BEN,204,.bj
2551+20,Bhutan,Kingdom of Bhutan,Independent State,,,Thimphu,BTN,Ngultrum,975,BT,BTN,64,.bt
2552+21,Bolivia,Republic of Bolivia,Independent State,,,La Paz (administrative/legislative) and Sucre (judical),BOB,Boliviano,591,BO,BOL,68,.bo
2553+22,Bosnia and Herzegovina,,Independent State,,,Sarajevo,BAM,Marka,387,BA,BIH,70,.ba
2554+23,Botswana,Republic of Botswana,Independent State,,,Gaborone,BWP,Pula,267,BW,BWA,72,.bw
2555+24,Brazil,Federative Republic of Brazil,Independent State,,,Brasilia,BRL,Real,55,BR,BRA,76,.br
2556+25,Brunei,Negara Brunei Darussalam,Independent State,,,Bandar Seri Begawan,BND,Dollar,673,BN,BRN,96,.bn
2557+26,Bulgaria,Republic of Bulgaria,Independent State,,,Sofia,BGN,Lev,359,BG,BGR,100,.bg
2558+27,Burkina Faso,,Independent State,,,Ouagadougou,XOF,Franc,226,BF,BFA,854,.bf
2559+28,Burundi,Republic of Burundi,Independent State,,,Bujumbura,BIF,Franc,257,BI,BDI,108,.bi
2560+29,Cambodia,Kingdom of Cambodia,Independent State,,,Phnom Penh,KHR,Riels,855,KH,KHM,116,.kh
2561+30,Cameroon,Republic of Cameroon,Independent State,,,Yaounde,XAF,Franc,237,CM,CMR,120,.cm
2562+31,Canada,,Independent State,,,Ottawa,CAD,Dollar,1,CA,CAN,124,.ca
2563+32,Cape Verde,Republic of Cape Verde,Independent State,,,Praia,CVE,Escudo,238,CV,CPV,132,.cv
2564+33,Central African Republic,,Independent State,,,Bangui,XAF,Franc,236,CF,CAF,140,.cf
2565+34,Chad,Republic of Chad,Independent State,,,N'Djamena,XAF,Franc,235,TD,TCD,148,.td
2566+35,Chile,Republic of Chile,Independent State,,,Santiago (administrative/judical) and Valparaiso (legislative),CLP,Peso,56,CL,CHL,152,.cl
2567+36,"China, People's Republic of",People's Republic of China,Independent State,,,Beijing,CNY,Yuan Renminbi,86,CN,CHN,156,.cn
2568+37,Colombia,Republic of Colombia,Independent State,,,Bogota,COP,Peso,57,CO,COL,170,.co
2569+38,Comoros,Union of Comoros,Independent State,,,Moroni,KMF,Franc,269,KM,COM,174,.km
2570+39,"Congo, (Congo – Kinshasa)",Democratic Republic of the Congo,Independent State,,,Kinshasa,CDF,Franc,243,CD,COD,180,.cd
2571+40,"Congo, (Congo – Brazzaville)",Republic of the Congo,Independent State,,,Brazzaville,XAF,Franc,242,CG,COG,178,.cg
2572+41,Costa Rica,Republic of Costa Rica,Independent State,,,San Jose,CRC,Colon,506,CR,CRI,188,.cr
2573+42,Cote d'Ivoire (Ivory Coast),Republic of Cote d'Ivoire,Independent State,,,Yamoussoukro,XOF,Franc,225,CI,CIV,384,.ci
2574+43,Croatia,Republic of Croatia,Independent State,,,Zagreb,HRK,Kuna,385,HR,HRV,191,.hr
2575+44,Cuba,Republic of Cuba,Independent State,,,Havana,CUP,Peso,53,CU,CUB,192,.cu
2576+45,Cyprus,Republic of Cyprus,Independent State,,,Nicosia,CYP,Pound,357,CY,CYP,196,.cy
2577+46,Czech Republic,,Independent State,,,Prague,CZK,Koruna,420,CZ,CZE,203,.cz
2578+47,Denmark,Kingdom of Denmark,Independent State,,,Copenhagen,DKK,Krone,45,DK,DNK,208,.dk
2579+48,Djibouti,Republic of Djibouti,Independent State,,,Djibouti,DJF,Franc,253,DJ,DJI,262,.dj
2580+49,Dominica,Commonwealth of Dominica,Independent State,,,Roseau,XCD,Dollar,-766,DM,DMA,212,.dm
2581+50,Dominican Republic,,Independent State,,,Santo Domingo,DOP,Peso,+1-809 and 1-829,DO,DOM,214,.do
2582+51,Ecuador,Republic of Ecuador,Independent State,,,Quito,USD,Dollar,593,EC,ECU,218,.ec
2583+52,Egypt,Arab Republic of Egypt,Independent State,,,Cairo,EGP,Pound,20,EG,EGY,818,.eg
2584+53,El Salvador,Republic of El Salvador,Independent State,,,San Salvador,USD,Dollar,503,SV,SLV,222,.sv
2585+54,Equatorial Guinea,Republic of Equatorial Guinea,Independent State,,,Malabo,XAF,Franc,240,GQ,GNQ,226,.gq
2586+55,Eritrea,State of Eritrea,Independent State,,,Asmara,ERN,Nakfa,291,ER,ERI,232,.er
2587+56,Estonia,Republic of Estonia,Independent State,,,Tallinn,EEK,Kroon,372,EE,EST,233,.ee
2588+57,Ethiopia,Federal Democratic Republic of Ethiopia,Independent State,,,Addis Ababa,ETB,Birr,251,ET,ETH,231,.et
2589+58,Fiji,Republic of the Fiji Islands,Independent State,,,Suva,FJD,Dollar,679,FJ,FJI,242,.fj
2590+59,Finland,Republic of Finland,Independent State,,,Helsinki,EUR,Euro,358,FI,FIN,246,.fi
2591+60,France,French Republic,Independent State,,,Paris,EUR,Euro,33,FR,FRA,250,.fr
2592+61,Gabon,Gabonese Republic,Independent State,,,Libreville,XAF,Franc,241,GA,GAB,266,.ga
2593+62,"Gambia, The",Republic of The Gambia,Independent State,,,Banjul,GMD,Dalasi,220,GM,GMB,270,.gm
2594+63,Georgia,Republic of Georgia,Independent State,,,Tbilisi,GEL,Lari,995,GE,GEO,268,.ge
2595+64,Germany,Federal Republic of Germany,Independent State,,,Berlin,EUR,Euro,49,DE,DEU,276,.de
2596+65,Ghana,Republic of Ghana,Independent State,,,Accra,GHC,Cedi,233,GH,GHA,288,.gh
2597+66,Greece,Hellenic Republic,Independent State,,,Athens,EUR,Euro,30,GR,GRC,300,.gr
2598+67,Grenada,,Independent State,,,Saint George's,XCD,Dollar,-472,GD,GRD,308,.gd
2599+68,Guatemala,Republic of Guatemala,Independent State,,,Guatemala,GTQ,Quetzal,502,GT,GTM,320,.gt
2600+69,Guinea,Republic of Guinea,Independent State,,,Conakry,GNF,Franc,224,GN,GIN,324,.gn
2601+70,Guinea-Bissau,Republic of Guinea-Bissau,Independent State,,,Bissau,XOF,Franc,245,GW,GNB,624,.gw
2602+71,Guyana,Co-operative Republic of Guyana,Independent State,,,Georgetown,GYD,Dollar,592,GY,GUY,328,.gy
2603+72,Haiti,Republic of Haiti,Independent State,,,Port-au-Prince,HTG,Gourde,509,HT,HTI,332,.ht
2604+73,Honduras,Republic of Honduras,Independent State,,,Tegucigalpa,HNL,Lempira,504,HN,HND,340,.hn
2605+74,Hungary,Republic of Hungary,Independent State,,,Budapest,HUF,Forint,36,HU,HUN,348,.hu
2606+75,Iceland,Republic of Iceland,Independent State,,,Reykjavik,ISK,Krona,354,IS,ISL,352,.is
2607+76,India,Republic of India,Independent State,,,New Delhi,INR,Rupee,91,IN,IND,356,.in
2608+77,Indonesia,Republic of Indonesia,Independent State,,,Jakarta,IDR,Rupiah,62,ID,IDN,360,.id
2609+78,Iran,Islamic Republic of Iran,Independent State,,,Tehran,IRR,Rial,98,IR,IRN,364,.ir
2610+79,Iraq,Republic of Iraq,Independent State,,,Baghdad,IQD,Dinar,964,IQ,IRQ,368,.iq
2611+80,Ireland,,Independent State,,,Dublin,EUR,Euro,353,IE,IRL,372,.ie
2612+81,Israel,State of Israel,Independent State,,,Jerusalem,ILS,Shekel,972,IL,ISR,376,.il
2613+82,Italy,Italian Republic,Independent State,,,Rome,EUR,Euro,39,IT,ITA,380,.it
2614+83,Jamaica,,Independent State,,,Kingston,JMD,Dollar,-875,JM,JAM,388,.jm
2615+84,Japan,,Independent State,,,Tokyo,JPY,Yen,81,JP,JPN,392,.jp
2616+85,Jordan,Hashemite Kingdom of Jordan,Independent State,,,Amman,JOD,Dinar,962,JO,JOR,400,.jo
2617+86,Kazakhstan,Republic of Kazakhstan,Independent State,,,Astana,KZT,Tenge,7,KZ,KAZ,398,.kz
2618+87,Kenya,Republic of Kenya,Independent State,,,Nairobi,KES,Shilling,254,KE,KEN,404,.ke
2619+88,Kiribati,Republic of Kiribati,Independent State,,,Tarawa,AUD,Dollar,686,KI,KIR,296,.ki
2620+89,"Korea, North",Democratic People's Republic of Korea,Independent State,,,Pyongyang,KPW,Won,850,KP,PRK,408,.kp
2621+90,"Korea, South",Republic of Korea,Independent State,,,Seoul,KRW,Won,82,KR,KOR,410,.kr
2622+91,Kuwait,State of Kuwait,Independent State,,,Kuwait,KWD,Dinar,965,KW,KWT,414,.kw
2623+92,Kyrgyzstan,Kyrgyz Republic,Independent State,,,Bishkek,KGS,Som,996,KG,KGZ,417,.kg
2624+93,Laos,Lao People's Democratic Republic,Independent State,,,Vientiane,LAK,Kip,856,LA,LAO,418,.la
2625+94,Latvia,Republic of Latvia,Independent State,,,Riga,LVL,Lat,371,LV,LVA,428,.lv
2626+95,Lebanon,Lebanese Republic,Independent State,,,Beirut,LBP,Pound,961,LB,LBN,422,.lb
2627+96,Lesotho,Kingdom of Lesotho,Independent State,,,Maseru,LSL,Loti,266,LS,LSO,426,.ls
2628+97,Liberia,Republic of Liberia,Independent State,,,Monrovia,LRD,Dollar,231,LR,LBR,430,.lr
2629+98,Libya,Great Socialist People's Libyan Arab Jamahiriya,Independent State,,,Tripoli,LYD,Dinar,218,LY,LBY,434,.ly
2630+99,Liechtenstein,Principality of Liechtenstein,Independent State,,,Vaduz,CHF,Franc,423,LI,LIE,438,.li
2631+100,Lithuania,Republic of Lithuania,Independent State,,,Vilnius,LTL,Litas,370,LT,LTU,440,.lt
2632+101,Luxembourg,Grand Duchy of Luxembourg,Independent State,,,Luxembourg,EUR,Euro,352,LU,LUX,442,.lu
2633+102,Macedonia,Republic of Macedonia,Independent State,,,Skopje,MKD,Denar,389,MK,MKD,807,.mk
2634+103,Madagascar,Republic of Madagascar,Independent State,,,Antananarivo,MGA,Ariary,261,MG,MDG,450,.mg
2635+104,Malawi,Republic of Malawi,Independent State,,,Lilongwe,MWK,Kwacha,265,MW,MWI,454,.mw
2636+105,Malaysia,,Independent State,,,Kuala Lumpur (legislative/judical) and Putrajaya (administrative),MYR,Ringgit,60,MY,MYS,458,.my
2637+106,Maldives,Republic of Maldives,Independent State,,,Male,MVR,Rufiyaa,960,MV,MDV,462,.mv
2638+107,Mali,Republic of Mali,Independent State,,,Bamako,XOF,Franc,223,ML,MLI,466,.ml
2639+108,Malta,Republic of Malta,Independent State,,,Valletta,MTL,Lira,356,MT,MLT,470,.mt
2640+109,Marshall Islands,Republic of the Marshall Islands,Independent State,,,Majuro,USD,Dollar,692,MH,MHL,584,.mh
2641+110,Mauritania,Islamic Republic of Mauritania,Independent State,,,Nouakchott,MRO,Ouguiya,222,MR,MRT,478,.mr
2642+111,Mauritius,Republic of Mauritius,Independent State,,,Port Louis,MUR,Rupee,230,MU,MUS,480,.mu
2643+112,Mexico,United Mexican States,Independent State,,,Mexico,MXN,Peso,52,MX,MEX,484,.mx
2644+113,Micronesia,Federated States of Micronesia,Independent State,,,Palikir,USD,Dollar,691,FM,FSM,583,.fm
2645+114,Moldova,Republic of Moldova,Independent State,,,Chisinau,MDL,Leu,373,MD,MDA,498,.md
2646+115,Monaco,Principality of Monaco,Independent State,,,Monaco,EUR,Euro,377,MC,MCO,492,.mc
2647+116,Mongolia,,Independent State,,,Ulaanbaatar,MNT,Tugrik,976,MN,MNG,496,.mn
2648+117,Montenegro,Republic of Montenegro,Independent State,,,Podgorica,EUR,Euro,382,ME,MNE,499,.me and .yu
2649+118,Morocco,Kingdom of Morocco,Independent State,,,Rabat,MAD,Dirham,212,MA,MAR,504,.ma
2650+119,Mozambique,Republic of Mozambique,Independent State,,,Maputo,MZM,Meticail,258,MZ,MOZ,508,.mz
2651+120,Myanmar (Burma),Union of Myanmar,Independent State,,,Naypyidaw,MMK,Kyat,95,MM,MMR,104,.mm
2652+121,Namibia,Republic of Namibia,Independent State,,,Windhoek,NAD,Dollar,264,NA,NAM,516,.na
2653+122,Nauru,Republic of Nauru,Independent State,,,Yaren,AUD,Dollar,674,NR,NRU,520,.nr
2654+123,Nepal,,Independent State,,,Kathmandu,NPR,Rupee,977,NP,NPL,524,.np
2655+124,Netherlands,Kingdom of the Netherlands,Independent State,,,Amsterdam (administrative) and The Hague (legislative/judical),EUR,Euro,31,NL,NLD,528,.nl
2656+125,New Zealand,,Independent State,,,Wellington,NZD,Dollar,64,NZ,NZL,554,.nz
2657+126,Nicaragua,Republic of Nicaragua,Independent State,,,Managua,NIO,Cordoba,505,NI,NIC,558,.ni
2658+127,Niger,Republic of Niger,Independent State,,,Niamey,XOF,Franc,227,NE,NER,562,.ne
2659+128,Nigeria,Federal Republic of Nigeria,Independent State,,,Abuja,NGN,Naira,234,NG,NGA,566,.ng
2660+129,Norway,Kingdom of Norway,Independent State,,,Oslo,NOK,Krone,47,NO,NOR,578,.no
2661+130,Oman,Sultanate of Oman,Independent State,,,Muscat,OMR,Rial,968,OM,OMN,512,.om
2662+131,Pakistan,Islamic Republic of Pakistan,Independent State,,,Islamabad,PKR,Rupee,92,PK,PAK,586,.pk
2663+132,Palau,Republic of Palau,Independent State,,,Melekeok,USD,Dollar,680,PW,PLW,585,.pw
2664+133,Panama,Republic of Panama,Independent State,,,Panama,PAB,Balboa,507,PA,PAN,591,.pa
2665+134,Papua New Guinea,Independent State of Papua New Guinea,Independent State,,,Port Moresby,PGK,Kina,675,PG,PNG,598,.pg
2666+135,Paraguay,Republic of Paraguay,Independent State,,,Asuncion,PYG,Guarani,595,PY,PRY,600,.py
2667+136,Peru,Republic of Peru,Independent State,,,Lima,PEN,Sol,51,PE,PER,604,.pe
2668+137,Philippines,Republic of the Philippines,Independent State,,,Manila,PHP,Peso,63,PH,PHL,608,.ph
2669+138,Poland,Republic of Poland,Independent State,,,Warsaw,PLN,Zloty,48,PL,POL,616,.pl
2670+139,Portugal,Portuguese Republic,Independent State,,,Lisbon,EUR,Euro,351,PT,PRT,620,.pt
2671+140,Qatar,State of Qatar,Independent State,,,Doha,QAR,Rial,974,QA,QAT,634,.qa
2672+141,Romania,,Independent State,,,Bucharest,RON,Leu,40,RO,ROU,642,.ro
2673+142,Russia,Russian Federation,Independent State,,,Moscow,RUB,Ruble,7,RU,RUS,643,.ru and .su
2674+143,Rwanda,Republic of Rwanda,Independent State,,,Kigali,RWF,Franc,250,RW,RWA,646,.rw
2675+144,Saint Kitts and Nevis,Federation of Saint Kitts and Nevis,Independent State,,,Basseterre,XCD,Dollar,-868,KN,KNA,659,.kn
2676+145,Saint Lucia,,Independent State,,,Castries,XCD,Dollar,-757,LC,LCA,662,.lc
2677+146,Saint Vincent and the Grenadines,,Independent State,,,Kingstown,XCD,Dollar,-783,VC,VCT,670,.vc
2678+147,Samoa,Independent State of Samoa,Independent State,,,Apia,WST,Tala,685,WS,WSM,882,.ws
2679+148,San Marino,Republic of San Marino,Independent State,,,San Marino,EUR,Euro,378,SM,SMR,674,.sm
2680+149,Sao Tome and Principe,Democratic Republic of Sao Tome and Principe,Independent State,,,Sao Tome,STD,Dobra,239,ST,STP,678,.st
2681+150,Saudi Arabia,Kingdom of Saudi Arabia,Independent State,,,Riyadh,SAR,Rial,966,SA,SAU,682,.sa
2682+151,Senegal,Republic of Senegal,Independent State,,,Dakar,XOF,Franc,221,SN,SEN,686,.sn
2683+152,Serbia,Republic of Serbia,Independent State,,,Belgrade,RSD,Dinar,381,RS,SRB,688,.rs and .yu
2684+153,Seychelles,Republic of Seychelles,Independent State,,,Victoria,SCR,Rupee,248,SC,SYC,690,.sc
2685+154,Sierra Leone,Republic of Sierra Leone,Independent State,,,Freetown,SLL,Leone,232,SL,SLE,694,.sl
2686+155,Singapore,Republic of Singapore,Independent State,,,Singapore,SGD,Dollar,65,SG,SGP,702,.sg
2687+156,Slovakia,Slovak Republic,Independent State,,,Bratislava,SKK,Koruna,421,SK,SVK,703,.sk
2688+157,Slovenia,Republic of Slovenia,Independent State,,,Ljubljana,EUR,Euro,386,SI,SVN,705,.si
2689+158,Solomon Islands,,Independent State,,,Honiara,SBD,Dollar,677,SB,SLB,90,.sb
2690+159,Somalia,,Independent State,,,Mogadishu,SOS,Shilling,252,SO,SOM,706,.so
2691+160,South Africa,Republic of South Africa,Independent State,,,"Pretoria (administrative), Cape Town (legislative), and Bloemfontein (judical)",ZAR,Rand,27,ZA,ZAF,710,.za
2692+161,Spain,Kingdom of Spain,Independent State,,,Madrid,EUR,Euro,34,ES,ESP,724,.es
2693+162,Sri Lanka,Democratic Socialist Republic of Sri Lanka,Independent State,,,Colombo (administrative/judical) and Sri Jayewardenepura Kotte (legislative),LKR,Rupee,94,LK,LKA,144,.lk
2694+163,Sudan,Republic of the Sudan,Independent State,,,Khartoum,SDD,Dinar,249,SD,SDN,736,.sd
2695+164,Suriname,Republic of Suriname,Independent State,,,Paramaribo,SRD,Dollar,597,SR,SUR,740,.sr
2696+165,Swaziland,Kingdom of Swaziland,Independent State,,,Mbabane (administrative) and Lobamba (legislative),SZL,Lilangeni,268,SZ,SWZ,748,.sz
2697+166,Sweden,Kingdom of Sweden,Independent State,,,Stockholm,SEK,Kronoa,46,SE,SWE,752,.se
2698+167,Switzerland,Swiss Confederation,Independent State,,,Bern,CHF,Franc,41,CH,CHE,756,.ch
2699+168,Syria,Syrian Arab Republic,Independent State,,,Damascus,SYP,Pound,963,SY,SYR,760,.sy
2700+169,Tajikistan,Republic of Tajikistan,Independent State,,,Dushanbe,TJS,Somoni,992,TJ,TJK,762,.tj
2701+170,Tanzania,United Republic of Tanzania,Independent State,,,Dar es Salaam (administrative/judical) and Dodoma (legislative),TZS,Shilling,255,TZ,TZA,834,.tz
2702+171,Thailand,Kingdom of Thailand,Independent State,,,Bangkok,THB,Baht,66,TH,THA,764,.th
2703+172,Timor-Leste (East Timor),Democratic Republic of Timor-Leste,Independent State,,,Dili,USD,Dollar,670,TL,TLS,626,.tp and .tl
2704+173,Togo,Togolese Republic,Independent State,,,Lome,XOF,Franc,228,TG,TGO,768,.tg
2705+174,Tonga,Kingdom of Tonga,Independent State,,,Nuku'alofa,TOP,Pa'anga,676,TO,TON,776,.to
2706+175,Trinidad and Tobago,Republic of Trinidad and Tobago,Independent State,,,Port-of-Spain,TTD,Dollar,-867,TT,TTO,780,.tt
2707+176,Tunisia,Tunisian Republic,Independent State,,,Tunis,TND,Dinar,216,TN,TUN,788,.tn
2708+177,Turkey,Republic of Turkey,Independent State,,,Ankara,TRY,Lira,90,TR,TUR,792,.tr
2709+178,Turkmenistan,,Independent State,,,Ashgabat,TMM,Manat,993,TM,TKM,795,.tm
2710+179,Tuvalu,,Independent State,,,Funafuti,AUD,Dollar,688,TV,TUV,798,.tv
2711+180,Uganda,Republic of Uganda,Independent State,,,Kampala,UGX,Shilling,256,UG,UGA,800,.ug
2712+181,Ukraine,,Independent State,,,Kiev,UAH,Hryvnia,380,UA,UKR,804,.ua
2713+182,United Arab Emirates,United Arab Emirates,Independent State,,,Abu Dhabi,AED,Dirham,971,AE,ARE,784,.ae
2714+183,Jersey,Bailiwick of Jersey,Dependency,Crown Dependency,United Kingdom,Saint Helier,JEP,Pound,44,JE,JEY,832,.je
2715+184,United States,United States of America,Independent State,,,Washington,USD,Dollar,1,US,USA,840,.us
2716+185,Uruguay,Oriental Republic of Uruguay,Independent State,,,Montevideo,UYU,Peso,598,UY,URY,858,.uy
2717+186,Uzbekistan,Republic of Uzbekistan,Independent State,,,Tashkent,UZS,Som,998,UZ,UZB,860,.uz
2718+187,Vanuatu,Republic of Vanuatu,Independent State,,,Port-Vila,VUV,Vatu,678,VU,VUT,548,.vu
2719+188,Vatican City,State of the Vatican City,Independent State,,,Vatican City,EUR,Euro,379,VA,VAT,336,.va
2720+189,Venezuela,Bolivarian Republic of Venezuela,Independent State,,,Caracas,VEB,Bolivar,58,VE,VEN,862,.ve
2721+190,Vietnam,Socialist Republic of Vietnam,Independent State,,,Hanoi,VND,Dong,84,VN,VNM,704,.vn
2722+191,Yemen,Republic of Yemen,Independent State,,,Sanaa,YER,Rial,967,YE,YEM,887,.ye
2723+192,Zambia,Republic of Zambia,Independent State,,,Lusaka,ZMK,Kwacha,260,ZM,ZMB,894,.zm
2724+193,Zimbabwe,Republic of Zimbabwe,Independent State,,,Harare,ZWD,Dollar,263,ZW,ZWE,716,.zw
2725+194,Abkhazia,Republic of Abkhazia,Proto Independent State,,,Sokhumi,RUB,Ruble,995,GE,GEO,268,.ge
2726+195,"China, Republic of (Taiwan)",Republic of China,Proto Independent State,,,Taipei,TWD,Dollar,886,TW,TWN,158,.tw
2727+196,Nagorno-Karabakh,Nagorno-Karabakh Republic,Proto Independent State,,,Stepanakert,AMD,Dram,277,AZ,AZE,31,.az
2728+197,Northern Cyprus,Turkish Republic of Northern Cyprus,Proto Independent State,,,Nicosia,TRY,Lira,-302,CY,CYP,196,.nc.tr
2729+198,Pridnestrovie (Transnistria),Pridnestrovian Moldavian Republic,Proto Independent State,,,Tiraspol,,Ruple,-160,MD,MDA,498,.md
2730+199,Somaliland,Republic of Somaliland,Proto Independent State,,,Hargeisa,,Shilling,252,SO,SOM,706,.so
2731+200,South Ossetia,Republic of South Ossetia,Proto Independent State,,,Tskhinvali,RUB and GEL,Ruble and Lari,995,GE,GEO,268,.ge
2732+201,Ashmore and Cartier Islands,Territory of Ashmore and Cartier Islands,Dependency,External Territory,Australia,,,,,AU,AUS,36,.au
2733+202,Christmas Island,Territory of Christmas Island,Dependency,External Territory,Australia,The Settlement (Flying Fish Cove),AUD,Dollar,61,CX,CXR,162,.cx
2734+203,Cocos (Keeling) Islands,Territory of Cocos (Keeling) Islands,Dependency,External Territory,Australia,West Island,AUD,Dollar,61,CC,CCK,166,.cc
2735+204,Coral Sea Islands,Coral Sea Islands Territory,Dependency,External Territory,Australia,,,,,AU,AUS,36,.au
2736+205,Heard Island and McDonald Islands,Territory of Heard Island and McDonald Islands,Dependency,External Territory,Australia,,,,,HM,HMD,334,.hm
2737+206,Norfolk Island,Territory of Norfolk Island,Dependency,External Territory,Australia,Kingston,AUD,Dollar,672,NF,NFK,574,.nf
2738+207,New Caledonia,,Dependency,Sui generis Collectivity,France,Noumea,XPF,Franc,687,NC,NCL,540,.nc
2739+208,French Polynesia,Overseas Country of French Polynesia,Dependency,Overseas Collectivity,France,Papeete,XPF,Franc,689,PF,PYF,258,.pf
2740+209,Mayotte,Departmental Collectivity of Mayotte,Dependency,Overseas Collectivity,France,Mamoudzou,EUR,Euro,262,YT,MYT,175,.yt
2741+210,Saint Barthelemy,Collectivity of Saint Barthelemy,Dependency,Overseas Collectivity,France,Gustavia,EUR,Euro,590,GP,GLP,312,.gp
2742+211,Saint Martin,Collectivity of Saint Martin,Dependency,Overseas Collectivity,France,Marigot,EUR,Euro,590,GP,GLP,312,.gp
2743+212,Saint Pierre and Miquelon,Territorial Collectivity of Saint Pierre and Miquelon,Dependency,Overseas Collectivity,France,Saint-Pierre,EUR,Euro,508,PM,SPM,666,.pm
2744+213,Wallis and Futuna,Collectivity of the Wallis and Futuna Islands,Dependency,Overseas Collectivity,France,Mata'utu,XPF,Franc,681,WF,WLF,876,.wf
2745+214,French Southern and Antarctic Lands,Territory of the French Southern and Antarctic Lands,Dependency,Overseas Territory,France,Martin-de-Viviès,,,,TF,ATF,260,.tf
2746+215,Clipperton Island,,Dependency,Possession,France,,,,,PF,PYF,258,.pf
2747+216,Bouvet Island,,Dependency,Territory,Norway,,,,,BV,BVT,74,.bv
2748+217,Cook Islands,,Dependency,Self-Governing in Free Association,New Zealand,Avarua,NZD,Dollar,682,CK,COK,184,.ck
2749+218,Niue,,Dependency,Self-Governing in Free Association,New Zealand,Alofi,NZD,Dollar,683,NU,NIU,570,.nu
2750+219,Tokelau,,Dependency,Territory,New Zealand,,NZD,Dollar,690,TK,TKL,772,.tk
2751+220,Guernsey,Bailiwick of Guernsey,Dependency,Crown Dependency,United Kingdom,Saint Peter Port,GGP,Pound,44,GG,GGY,831,.gg
2752+221,Isle of Man,,Dependency,Crown Dependency,United Kingdom,Douglas,IMP,Pound,44,IM,IMN,833,.im
2753+222,United Kingdom,United Kingdom of Great Britain and Northern Ireland,Independent State,,,London,GBP,Pound,44,GB,GBR,826,.uk
2754+223,Anguilla,,Dependency,Overseas Territory,United Kingdom,The Valley,XCD,Dollar,-263,AI,AIA,660,.ai
2755+224,Bermuda,,Dependency,Overseas Territory,United Kingdom,Hamilton,BMD,Dollar,-440,BM,BMU,60,.bm
2756+225,British Indian Ocean Territory,,Dependency,Overseas Territory,United Kingdom,,,,246,IO,IOT,86,.io
2757+226,British Sovereign Base Areas,,Dependency,Overseas Territory,United Kingdom,Episkopi,CYP,Pound,357,,,,
2758+227,British Virgin Islands,,Dependency,Overseas Territory,United Kingdom,Road Town,USD,Dollar,-283,VG,VGB,92,.vg
2759+228,Cayman Islands,,Dependency,Overseas Territory,United Kingdom,George Town,KYD,Dollar,-344,KY,CYM,136,.ky
2760+229,Falkland Islands (Islas Malvinas),,Dependency,Overseas Territory,United Kingdom,Stanley,FKP,Pound,500,FK,FLK,238,.fk
2761+230,Gibraltar,,Dependency,Overseas Territory,United Kingdom,Gibraltar,GIP,Pound,350,GI,GIB,292,.gi
2762+231,Montserrat,,Dependency,Overseas Territory,United Kingdom,Plymouth,XCD,Dollar,-663,MS,MSR,500,.ms
2763+232,Pitcairn Islands,,Dependency,Overseas Territory,United Kingdom,Adamstown,NZD,Dollar,,PN,PCN,612,.pn
2764+233,Saint Helena,,Dependency,Overseas Territory,United Kingdom,Jamestown,SHP,Pound,290,SH,SHN,654,.sh
2765+234,South Georgia & South Sandwich Islands,,Dependency,Overseas Territory,United Kingdom,,,,,GS,SGS,239,.gs
2766+235,Turks and Caicos Islands,,Dependency,Overseas Territory,United Kingdom,Grand Turk,USD,Dollar,-648,TC,TCA,796,.tc
2767+236,Northern Mariana Islands,Commonwealth of The Northern Mariana Islands,Dependency,Commonwealth,United States,Saipan,USD,Dollar,-669,MP,MNP,580,.mp
2768+237,Puerto Rico,Commonwealth of Puerto Rico,Dependency,Commonwealth,United States,San Juan,USD,Dollar,+1-787 and 1-939,PR,PRI,630,.pr
2769+238,American Samoa,Territory of American Samoa,Dependency,Territory,United States,Pago Pago,USD,Dollar,-683,AS,ASM,16,.as
2770+239,Baker Island,,Dependency,Territory,United States,,,,,UM,UMI,581,
2771+240,Guam,Territory of Guam,Dependency,Territory,United States,Hagatna,USD,Dollar,-670,GU,GUM,316,.gu
2772+241,Howland Island,,Dependency,Territory,United States,,,,,UM,UMI,581,
2773+242,Jarvis Island,,Dependency,Territory,United States,,,,,UM,UMI,581,
2774+243,Johnston Atoll,,Dependency,Territory,United States,,,,,UM,UMI,581,
2775+244,Kingman Reef,,Dependency,Territory,United States,,,,,UM,UMI,581,
2776+245,Midway Islands,,Dependency,Territory,United States,,,,,UM,UMI,581,
2777+246,Navassa Island,,Dependency,Territory,United States,,,,,UM,UMI,581,
2778+247,Palmyra Atoll,,Dependency,Territory,United States,,,,,UM,UMI,581,
2779+248,U.S. Virgin Islands,United States Virgin Islands,Dependency,Territory,United States,Charlotte Amalie,USD,Dollar,-339,VI,VIR,850,.vi
2780+249,Wake Island,,Dependency,Territory,United States,,,,,UM,UMI,850,
2781+250,Hong Kong,Hong Kong Special Administrative Region,Proto Dependency,Special Administrative Region,China,,HKD,Dollar,852,HK,HKG,344,.hk
2782+251,Macau,Macau Special Administrative Region,Proto Dependency,Special Administrative Region,China,Macau,MOP,Pataca,853,MO,MAC,446,.mo
2783+252,Faroe Islands,,Proto Dependency,,Denmark,Torshavn,DKK,Krone,298,FO,FRO,234,.fo
2784+253,Greenland,,Proto Dependency,,Denmark,Nuuk (Godthab),DKK,Krone,299,GL,GRL,304,.gl
2785+254,French Guiana,Overseas Region of Guiana,Proto Dependency,Overseas Region,France,Cayenne,EUR,Euro,594,GF,GUF,254,.gf
2786+255,Guadeloupe,Overseas Region of Guadeloupe,Proto Dependency,Overseas Region,France,Basse-Terre,EUR,Euro,590,GP,GLP,312,.gp
2787+256,Martinique,Overseas Region of Martinique,Proto Dependency,Overseas Region,France,Fort-de-France,EUR,Euro,596,MQ,MTQ,474,.mq
2788+257,Reunion,Overseas Region of Reunion,Proto Dependency,Overseas Region,France,Saint-Denis,EUR,Euro,262,RE,REU,638,.re
2789+258,Aland,,Proto Dependency,,Finland,Mariehamn,EUR,Euro,340,AX,ALA,248,.ax
2790+259,Aruba,,Proto Dependency,,Netherlands,Oranjestad,AWG,Guilder,297,AW,ABW,533,.aw
2791+260,Netherlands Antilles,,Proto Dependency,,Netherlands,Willemstad,ANG,Guilder,599,AN,ANT,530,.an
2792+261,Svalbard,,Proto Dependency,,Norway,Longyearbyen,NOK,Krone,47,SJ,SJM,744,.sj
2793+262,Ascension,,Proto Dependency,Dependency of Saint Helena,United Kingdom,Georgetown,SHP,Pound,247,AC,ASC,,.ac
2794+263,Tristan da Cunha,,Proto Dependency,Dependency of Saint Helena,United Kingdom,Edinburgh,SHP,Pound,290,TA,TAA,,
2795+268,Australian Antarctic Territory,,Antarctic Territory,External Territory,Australia,,,,,AQ,ATA,10,.aq
2796+269,Ross Dependency,,Antarctic Territory,Territory,New Zealand,,,,,AQ,ATA,10,.aq
2797+270,Peter I Island,,Antarctic Territory,Territory,Norway,,,,,AQ,ATA,10,.aq
2798+271,Queen Maud Land,,Antarctic Territory,Territory,Norway,,,,,AQ,ATA,10,.aq
2799+272,British Antarctic Territory,,Antarctic Territory,Overseas Territory,United Kingdom,,,,,AQ,ATA,10,.aq
2800
2801=== added directory 'components/listitems'
2802=== added file 'components/listitems/CMakeLists.txt'
2803--- components/listitems/CMakeLists.txt 1970-01-01 00:00:00 +0000
2804+++ components/listitems/CMakeLists.txt 2014-10-11 18:44:23 +0000
2805@@ -0,0 +1,7 @@
2806+file(GLOB LISTITEMS_QML_JS_FILES *.qml *.js)
2807+
2808+# make the files visible in the qtcreator tree
2809+add_custom_target(telegram_listitems_QMlFiles ALL SOURCES ${LISTITEMS_QML_JS_FILES})
2810+
2811+install(FILES ${LISTITEMS_QML_JS_FILES} DESTINATION ${TELEGRAM_DIR}/components/listitems)
2812+install(DIRECTORY "artwork" DESTINATION ${TELEGRAM_DIR}/components/listitems)
2813
2814=== added file 'components/listitems/DlgItem.qml'
2815--- components/listitems/DlgItem.qml 1970-01-01 00:00:00 +0000
2816+++ components/listitems/DlgItem.qml 2014-10-11 18:44:23 +0000
2817@@ -0,0 +1,15 @@
2818+import QtQuick 2.0
2819+
2820+DlgItemDesign {
2821+
2822+ onClicked: {
2823+ console.log("INDEX" + index);
2824+ console.log("element:" + telegramClient.dialogsModel.get(index));
2825+ dialogPage.peerId = telegramClient.dialogsModel.get(index).id;
2826+ dialogPage.peerIsChat = telegramClient.dialogsModel.get(index).isChat;
2827+ pageStack.showPage(dialogPage);
2828+
2829+ console.log("ID:" + dialogPage.peerId);
2830+ console.log("ISCHAT" + dialogPage.peerIsChat);
2831+ }
2832+}
2833
2834=== added file 'components/listitems/DlgItemDesign.qml'
2835--- components/listitems/DlgItemDesign.qml 1970-01-01 00:00:00 +0000
2836+++ components/listitems/DlgItemDesign.qml 2014-10-11 18:44:23 +0000
2837@@ -0,0 +1,226 @@
2838+import QtQuick 2.0
2839+import Ubuntu.Components 0.1
2840+import Ubuntu.Components.ListItems 0.1
2841+
2842+
2843+Empty {
2844+ id: baseListItem
2845+
2846+ /*!
2847+ \preliminary
2848+ The location of the icon to show in the list item (optional), or an Item that is
2849+ shown on the left side inside the list item. The icon will automatically be
2850+ anchored to the left side of the list item, and if its height is undefined, to the top
2851+ and bottom of the list item.
2852+ \qmlproperty variant icon
2853+ */
2854+ property variant icon
2855+
2856+ /*!
2857+ \preliminary
2858+ The location of the icon to show in the list item if iconSource failed to load (optional).
2859+ \qmlproperty url fallbackIconSource
2860+ */
2861+ property alias fallbackIconSource: iconHelper.fallbackSource
2862+
2863+ /*!
2864+ \preliminary
2865+ Show or hide the frame around the icon
2866+ \qmlproperty bool iconFrame
2867+ */
2868+ property alias iconFrame: iconHelper.hasFrame
2869+
2870+ /*!
2871+ \preliminary
2872+ The text that is shown in the list item as a label.
2873+ \qmlproperty string text
2874+ */
2875+ property alias text: label.text
2876+
2877+ /*!
2878+ \preliminary
2879+ The list of strings that will be shown under the label text
2880+ \qmlproperty string subText
2881+ */
2882+ property alias subText: subLabel.text
2883+
2884+ property alias date: date.text
2885+
2886+ property alias unread: unread.text
2887+
2888+ __height: Math.max(middleVisuals.height, units.gu(6))
2889+
2890+ __contentsMargins: units.gu(1)
2891+
2892+ property bool __iconIsItem: false
2893+
2894+ /*!
2895+ \internal
2896+ */
2897+ onIconChanged: {
2898+ __iconIsItem = (typeof icon != "string")
2899+ if (typeof icon == "string") {
2900+ // icon is the url of an image
2901+ iconHelper.source = icon;
2902+ __iconIsItem = false;
2903+ } else {
2904+ // icon is an Item.
2905+ __iconIsItem = true;
2906+ iconHelper.source = "";
2907+
2908+// icon.parent = baseListItem;
2909+// icon.anchors.left = baseListItem.left;
2910+// icon.anchors.margins = Qt.binding(function() { return baseListItem.__contentsMargins });
2911+// if (!icon.height) {
2912+// icon.anchors.top = baseListItem.top;
2913+// icon.anchors.bottom = baseListItem.bottom;
2914+// }
2915+ }
2916+ }
2917+
2918+ /*!
2919+ \internal
2920+ */
2921+ property alias children: middle.children
2922+
2923+ IconVisual {
2924+ id: iconHelper
2925+ width: height
2926+ height: Math.min(units.gu(5), parent.height - units.gu(1))
2927+ anchors {
2928+ left: parent.left
2929+ leftMargin: baseListItem.__contentsMargins
2930+ verticalCenter: parent.verticalCenter
2931+ }
2932+ }
2933+
2934+
2935+ Item {
2936+ id: middle
2937+ anchors {
2938+ top: parent.top
2939+ bottom: parent.bottom
2940+ left: iconHelper.right
2941+ right: parent.right
2942+ rightMargin: baseListItem.__contentsMargins
2943+ leftMargin: baseListItem.__contentsMargins
2944+ }
2945+
2946+ Item {
2947+ id: middleVisuals
2948+ anchors {
2949+ left: parent.left
2950+ right: parent.right
2951+ verticalCenter: parent.verticalCenter
2952+ }
2953+
2954+ height: childrenRect.height + labelRect.anchors.topMargin + subLabelRect.anchors.bottomMargin
2955+
2956+ Item {
2957+ id: upRow
2958+ anchors {
2959+ top: parent.top
2960+ left: parent.left
2961+ right: parent.right
2962+ }
2963+
2964+ height: iconHelper.height / 2.5
2965+
2966+ Item {
2967+ id: labelRect
2968+ anchors {
2969+ left: parent.left
2970+ right: dateRect.left
2971+ }
2972+ height: parent.height
2973+ width: childrenRect.width
2974+
2975+ LabelVisual {
2976+ anchors.fill: parent
2977+ id: label
2978+ font.weight: Font.Bold
2979+ wrapMode: Text.WrapAnywhere
2980+ maximumLineCount: 1
2981+ verticalAlignment: Text.AlignVCenter
2982+ horizontalAlignment: Text.AlignLeft
2983+ }
2984+ }
2985+
2986+ Item {
2987+ id: dateRect
2988+ anchors {
2989+ right: parent.right
2990+ }
2991+ height: parent.height
2992+ width: childrenRect.width
2993+
2994+ LabelVisual {
2995+ id: date
2996+ fontSize: "x-small"
2997+ wrapMode: Text.NoWrap
2998+ maximumLineCount: 1
2999+ verticalAlignment: Text.AlignVCenter
3000+ horizontalAlignment: Text.AlignHCenter
3001+ }
3002+ }
3003+
3004+ }
3005+
3006+
3007+ Item {
3008+ id: downRow
3009+ anchors {
3010+ top: upRow.bottom
3011+ left: parent.left
3012+ right: parent.right
3013+ }
3014+
3015+ height: iconHelper.height / 2.5
3016+
3017+ Item {
3018+ id: subLabelRect
3019+ anchors {
3020+ left: parent.left
3021+ right: unreadRect.left
3022+ }
3023+ height: parent.height
3024+ width: childrenRect.width
3025+
3026+ LabelVisual {
3027+ id: subLabel
3028+ anchors.fill: parent
3029+ fontSize: "small"
3030+ wrapMode: Text.WrapAnywhere
3031+ maximumLineCount: 1
3032+ verticalAlignment: Text.AlignBottom
3033+ horizontalAlignment: Text.AlignLeft
3034+ }
3035+ }
3036+
3037+ Rectangle {
3038+ id: unreadRect
3039+ anchors {
3040+ right: parent.right
3041+ }
3042+ visible: unread.text > '0'
3043+ color: "lightgreen"
3044+ height: parent.height
3045+ width: height//childrenRect.width
3046+
3047+ LabelVisual {
3048+ id: unread
3049+ anchors.fill: parent
3050+ fontSize: "x-small"
3051+ wrapMode: Text.NoWrap
3052+ maximumLineCount: 1
3053+ verticalAlignment: Text.AlignVCenter
3054+ horizontalAlignment: Text.AlignHCenter
3055+ }
3056+ }
3057+ }
3058+
3059+ }
3060+ }
3061+
3062+
3063+}
3064
3065=== added file 'components/listitems/IconVisual.qml'
3066--- components/listitems/IconVisual.qml 1970-01-01 00:00:00 +0000
3067+++ components/listitems/IconVisual.qml 2014-10-11 18:44:23 +0000
3068@@ -0,0 +1,52 @@
3069+/*
3070+ * Copyright 2012 Canonical Ltd.
3071+ *
3072+ * This program is free software; you can redistribute it and/or modify
3073+ * it under the terms of the GNU Lesser General Public License as published by
3074+ * the Free Software Foundation; version 3.
3075+ *
3076+ * This program is distributed in the hope that it will be useful,
3077+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
3078+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
3079+ * GNU Lesser General Public License for more details.
3080+ *
3081+ * You should have received a copy of the GNU Lesser General Public License
3082+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
3083+ */
3084+
3085+import QtQuick 2.0
3086+import Ubuntu.Components 0.1
3087+
3088+// internal helper class to create the visuals
3089+// for the icon.
3090+Item {
3091+ id: iconVisual
3092+
3093+ /*!
3094+ \qmlproperty url source
3095+ */
3096+ property alias source: icon.source
3097+ /*!
3098+ \qmlproperty url fallbackSource
3099+ */
3100+ property alias fallbackSource: icon.fallbackSource
3101+ visible: source != ""
3102+ property bool hasFrame: true
3103+
3104+ ImageWithFallback {
3105+ id: icon
3106+ visible: !iconVisual.hasFrame
3107+ opacity: iconVisual.enabled ? 1.0 : 0.5
3108+ fillMode: Image.PreserveAspectCrop
3109+ anchors.fill: parent
3110+ smooth: true
3111+ asynchronous: true
3112+ }
3113+
3114+ UbuntuShape {
3115+ id: shape
3116+ visible: iconVisual.hasFrame
3117+ anchors.fill: parent
3118+ image: icon
3119+ }
3120+}
3121
3122=== added file 'components/listitems/ImageWithFallback.qml'
3123--- components/listitems/ImageWithFallback.qml 1970-01-01 00:00:00 +0000
3124+++ components/listitems/ImageWithFallback.qml 2014-10-11 18:44:23 +0000
3125@@ -0,0 +1,46 @@
3126+/*
3127+ * Copyright 2012 Canonical Ltd.
3128+ *
3129+ * This program is free software; you can redistribute it and/or modify
3130+ * it under the terms of the GNU Lesser General Public License as published by
3131+ * the Free Software Foundation; version 3.
3132+ *
3133+ * This program is distributed in the hope that it will be useful,
3134+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
3135+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
3136+ * GNU Lesser General Public License for more details.
3137+ *
3138+ * You should have received a copy of the GNU Lesser General Public License
3139+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
3140+ */
3141+
3142+import QtQuick 2.0
3143+
3144+Image {
3145+ id: image
3146+
3147+ property url fallbackSource
3148+ property bool fallbackRequired: false
3149+
3150+ function isSourceDefined(sourceUrl) {
3151+ return sourceUrl != "" && sourceUrl != undefined
3152+ }
3153+
3154+ function tryLoadingFallbackSource() {
3155+ if (isSourceDefined(fallbackSource)) {
3156+ source = fallbackSource
3157+ }
3158+ }
3159+
3160+ function checkStatus() {
3161+ if (!isSourceDefined(source) || (status == Image.Error && source != fallbackSource)) {
3162+ fallbackRequired = true
3163+ tryLoadingFallbackSource()
3164+ }
3165+ }
3166+
3167+ onSourceChanged: fallbackRequired = false
3168+ onFallbackSourceChanged: if (fallbackRequired) tryLoadingFallbackSource()
3169+ onStatusChanged: checkStatus()
3170+ Component.onCompleted: checkStatus()
3171+}
3172
3173=== added file 'components/listitems/LabelVisual.qml'
3174--- components/listitems/LabelVisual.qml 1970-01-01 00:00:00 +0000
3175+++ components/listitems/LabelVisual.qml 2014-10-11 18:44:23 +0000
3176@@ -0,0 +1,38 @@
3177+/*
3178+ * Copyright 2012 Canonical Ltd.
3179+ *
3180+ * This program is free software; you can redistribute it and/or modify
3181+ * it under the terms of the GNU Lesser General Public License as published by
3182+ * the Free Software Foundation; version 3.
3183+ *
3184+ * This program is distributed in the hope that it will be useful,
3185+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
3186+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
3187+ * GNU Lesser General Public License for more details.
3188+ *
3189+ * You should have received a copy of the GNU Lesser General Public License
3190+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
3191+ */
3192+
3193+import QtQuick 2.0
3194+import Ubuntu.Components 0.1
3195+
3196+// internal helper class for text inside the list items.
3197+Label {
3198+ id: label
3199+ property bool selected: false
3200+ property bool secondary: false
3201+
3202+ // FIXME: very ugly hack to detect whether the list item is inside a Popover
3203+ property bool overlay: isInsideOverlay(label)
3204+ function isInsideOverlay(item) {
3205+ if (!item.parent) return false;
3206+ return item.parent.hasOwnProperty("pointerTarget") || label.isInsideOverlay(item.parent)
3207+ }
3208+
3209+ fontSize: "medium"
3210+ elide: Text.ElideRight
3211+ color: selected ? UbuntuColors.orange : secondary ? overlay ? Theme.palette.normal.overlayText : Theme.palette.normal.backgroundText
3212+ : overlay ? Theme.palette.selected.overlayText : Theme.palette.selected.backgroundText
3213+ opacity: label.enabled ? 1.0 : 0.5
3214+}
3215
3216=== added file 'components/listitems/ProgressionVisual.qml'
3217--- components/listitems/ProgressionVisual.qml 1970-01-01 00:00:00 +0000
3218+++ components/listitems/ProgressionVisual.qml 2014-10-11 18:44:23 +0000
3219@@ -0,0 +1,52 @@
3220+/*
3221+ * Copyright 2012 Canonical Ltd.
3222+ *
3223+ * This program is free software; you can redistribute it and/or modify
3224+ * it under the terms of the GNU Lesser General Public License as published by
3225+ * the Free Software Foundation; version 3.
3226+ *
3227+ * This program is distributed in the hope that it will be useful,
3228+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
3229+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
3230+ * GNU Lesser General Public License for more details.
3231+ *
3232+ * You should have received a copy of the GNU Lesser General Public License
3233+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
3234+ */
3235+
3236+import QtQuick 2.0
3237+
3238+// Internal helper class for the visuals of
3239+// the progression symbol.
3240+Item {
3241+ id: progressionVisual
3242+
3243+ width: progressIcon.width + (showSplit ? splitMargin + progressionDivider.width : 0)
3244+
3245+ property bool showSplit: false
3246+ property real splitMargin
3247+
3248+ Image {
3249+ id: progressIcon
3250+ source: "artwork/ListItemProgressionArrow.png"
3251+ anchors {
3252+ verticalCenter: parent.verticalCenter
3253+ right: parent.right
3254+ }
3255+
3256+ opacity: enabled ? 1.0 : 0.5
3257+ }
3258+
3259+ Image {
3260+ id: progressionDivider
3261+ visible: progressionVisual.showSplit
3262+ anchors {
3263+ top: parent.top
3264+ bottom: parent.bottom
3265+ right: progressIcon.left
3266+ rightMargin: splitMargin
3267+ }
3268+ source: "artwork/ListItemDividerVertical.png"
3269+ opacity: enabled ? 1.0 : 0.5
3270+ }
3271+}
3272
3273=== added directory 'components/listitems/artwork'
3274=== added file 'components/listitems/artwork/ListItemDivider24px@8.png'
3275Binary files components/listitems/artwork/ListItemDivider24px@8.png 1970-01-01 00:00:00 +0000 and components/listitems/artwork/ListItemDivider24px@8.png 2014-10-11 18:44:23 +0000 differ
3276=== added file 'components/listitems/artwork/ListItemDivider6px@8.png'
3277Binary files components/listitems/artwork/ListItemDivider6px@8.png 1970-01-01 00:00:00 +0000 and components/listitems/artwork/ListItemDivider6px@8.png 2014-10-11 18:44:23 +0000 differ
3278=== added file 'components/listitems/artwork/ListItemDividerHorizontal@18.png'
3279Binary files components/listitems/artwork/ListItemDividerHorizontal@18.png 1970-01-01 00:00:00 +0000 and components/listitems/artwork/ListItemDividerHorizontal@18.png 2014-10-11 18:44:23 +0000 differ
3280=== added file 'components/listitems/artwork/ListItemDividerVertical@18.png'
3281Binary files components/listitems/artwork/ListItemDividerVertical@18.png 1970-01-01 00:00:00 +0000 and components/listitems/artwork/ListItemDividerVertical@18.png 2014-10-11 18:44:23 +0000 differ
3282=== added file 'components/listitems/artwork/ListItemProgressionArrow@8.png'
3283Binary files components/listitems/artwork/ListItemProgressionArrow@8.png 1970-01-01 00:00:00 +0000 and components/listitems/artwork/ListItemProgressionArrow@8.png 2014-10-11 18:44:23 +0000 differ
3284=== added file 'components/listitems/artwork/delete@8.png'
3285Binary files components/listitems/artwork/delete@8.png 1970-01-01 00:00:00 +0000 and components/listitems/artwork/delete@8.png 2014-10-11 18:44:23 +0000 differ
3286=== added file 'countries.py'
3287--- countries.py 1970-01-01 00:00:00 +0000
3288+++ countries.py 2014-10-11 18:44:23 +0000
3289@@ -0,0 +1,52 @@
3290+#!/usr/bin/env python3
3291+
3292+import csv
3293+import simplejson as json
3294+import operator
3295+
3296+def dump_json():
3297+ name_to_tel = {}
3298+ name_to_iso = {}
3299+ iso_to_name = {}
3300+ iso_to_tel = {}
3301+ tel_to_name = {}
3302+ tel_to_iso = {}
3303+
3304+ with open('components/iso_3166_2_countries.csv', encoding="utf-8") as f:
3305+ reader = csv.reader(f)
3306+ for row in reader:
3307+ name = row[1]
3308+ iso = row[10] # two letter country code
3309+ tel = row[9]
3310+
3311+ if not tel or not iso:
3312+ continue
3313+
3314+ name_to_tel[name] = tel
3315+ name_to_iso[name] = iso
3316+ iso_to_name[iso] = name
3317+ iso_to_tel[iso] = tel
3318+ tel_to_name[tel] = name
3319+ tel_to_iso[tel] = iso
3320+
3321+ with open('components/country_data.js', 'w') as f:
3322+ f.write("var name_to_tel = ")
3323+ f.write(json.dumps(name_to_tel))
3324+ f.write(";\n")
3325+ f.write("var name_to_iso = ")
3326+ f.write(json.dumps(name_to_iso))
3327+ f.write(";\n")
3328+ f.write("var iso_to_name = ")
3329+ f.write(json.dumps(iso_to_name))
3330+ f.write(";\n")
3331+ f.write("var iso_to_tel = ")
3332+ f.write(json.dumps(iso_to_tel))
3333+ f.write(";\n")
3334+ f.write("var tel_to_name = ")
3335+ f.write(json.dumps(tel_to_name))
3336+ f.write(";\n")
3337+ f.write("var tel_to_iso = ")
3338+ f.write(json.dumps(tel_to_iso))
3339+
3340+if __name__ == "__main__":
3341+ dump_json()
3342
3343=== added file 'debug.md'
3344--- debug.md 1970-01-01 00:00:00 +0000
3345+++ debug.md 2014-10-11 18:44:23 +0000
3346@@ -0,0 +1,110 @@
3347+====================
3348+Some debugging notes
3349+====================
3350+
3351+This document is still a work in progress.
3352+
3353+Here are some very rough notes on how to set up Telegram for debugging.
3354+
3355+Build the library in debug mode
3356+===============================
3357+Append to the cmake line in build.sh:
3358+
3359+ ${SDK_PATH}/qtc_chroot_cmake ${CLICK_SDK_ARCH} ${CLICK_SDK_FRAMEWORK} $SERIES ../.. -DCMAKE_BUILD_TYPE=Debug
3360+
3361+
3362+gdb + debug symbols
3363+===================
3364+When stepping through a stack trace in gdb, it may be useful to have debug
3365+symbols for the Qt libraries.
3366+
3367+In Ubuntu, the debug symbol packages are built and hosted on a different
3368+server from the standard source and binary packages. To get them:
3369+
3370+ echo "deb http://ddebs.ubuntu.com $(lsb_release -cs) main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list.d/ddebs.list
3371+ sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 428D7C01
3372+
3373+And then of course, issue ``sudo apt-get update``.
3374+
3375+The next step is to install the symbol packages. The package names correspond
3376+to the binary package names, with "-dbgsym" appended. For example, to get
3377+the symbols for qtbase5-dev:
3378+
3379+ sudo apt-get install qtbase5-dev-dbgsym
3380+
3381+Beware that the symbols can be quite large in terms of disk space, and it is
3382+assumed you are debugging with gdb on your desktop, where storage is less of
3383+an issue than a device.
3384+
3385+Finally, understand that installing debug symbols only partially improves
3386+the debugging experience in gdb. An additional nicety is to install the
3387+actual library source, so that you can easily view source code from gdb
3388+itself.
3389+
3390+Here is one technique to do so. First, download the actual source for the
3391+package you are interested in:
3392+
3393+ mkdir debug
3394+ cd debug
3395+ apt-get source qtbase5-dev
3396+ cd ..
3397+
3398+Next, you must start gdb properly so it knows how to find the new source
3399+files. The key rune below is: ``find debug -type d -printf '-d %p'``
3400+
3401+ LD_LIBRARY_PATH=$LD_LIBRARY_PATH:build/amd64/library/lib QML2_IMPORT_PATH=build/amd64/library/qmlplugin gdb qmlscene `find debug -type d -printf '-d %p '`
3402+
3403+After starting gdb, just a few extra commands, and you are on your
3404+way:
3405+
3406+ set args telegram.qml
3407+ r
3408+
3409+Now, when you get a crash and inspect the stack trace, you can view the
3410+source:
3411+
3412+ (gdb) bt
3413+ #0 0x00007ffff5232117 in __GI_raise (sig=sig@entry=6)
3414+ at ../nptl/sysdeps/unix/sysv/linux/raise.c:56
3415+ #1 0x00007ffff5233808 in __GI_abort () at abort.c:89
3416+ #2 0x00007ffff5273fd4 in __libc_message (do_abort=do_abort@entry=1,
3417+ fmt=fmt@entry=0x7ffff537dba8 "*** Error in `%s': %s: 0x%s ***\n")
3418+ at ../sysdeps/posix/libc_fatal.c:175
3419+ #3 0x00007ffff527b5e6 in malloc_printerr (ptr=<optimized out>,
3420+ str=0x7ffff537dc90 "double free or corruption (!prev)", action=1)
3421+ at malloc.c:4996
3422+ #4 _int_free (av=<optimized out>, p=<optimized out>, have_lock=0)
3423+ at malloc.c:3840
3424+ #5 0x00007ffff5ec9608 in QObject::event (this=0xc32780, e=<optimized out>)
3425+ at kernel/qobject.cpp:1232
3426+
3427+ (gdb) frame 5
3428+ #5 0x00007ffff5ec9608 in QObject::event (this=0xc32780, e=<optimized out>)
3429+ at kernel/qobject.cpp:1232
3430+ 1232 qDeleteInEventHandler(this);
3431+ (gdb) l
3432+ 1227 case QEvent::ChildRemoved:
3433+ 1228 childEvent((QChildEvent*)e);
3434+ 1229 break;
3435+ 1230
3436+ 1231 case QEvent::DeferredDelete:
3437+ 1232 qDeleteInEventHandler(this);
3438+ 1233 break;
3439+ 1234
3440+ 1235 case QEvent::MetaCall:
3441+ 1236 {
3442+
3443+
3444+Running with valgrind
3445+=====================
3446+Valgrind is a suite of tools, one of which is memcheck, which can be used to
3447+detect memory leaks. Running it can be a bit complex, but this rune should
3448+help:
3449+
3450+ LD_LIBRARY_PATH=$LD_LIBRARY_PATH:build/amd64/library/lib QML2_IMPORT_PATH=build/amd64/library/qmlplugin G_SLICE=always-malloc G_DEBUG=gc-friendly valgrind -v --tool=memcheck --leak-check=full --num-callers=40 --log-file=valgrind.log --track-origins=yes --trace-children=yes qmlscene telegram.qml
3451+
3452+If you find the log to be noisy, you may wish to suppress some of the
3453+warnings. Google for "valgrind suppressions" for the details. In the above
3454+rune, you can add ``--gen-suppressions=all`` to generate suppressions.
3455+
3456+Check out the ``tools/extract_suppressions.sh`` script and go from there.
3457
3458=== added directory 'images'
3459=== added file 'images/background_hd.jpg'
3460Binary files images/background_hd.jpg 1970-01-01 00:00:00 +0000 and images/background_hd.jpg 2014-10-11 18:44:23 +0000 differ
3461=== added file 'images/call.png'
3462Binary files images/call.png 1970-01-01 00:00:00 +0000 and images/call.png 2014-10-11 18:44:23 +0000 differ
3463=== added file 'images/conversation_incoming@27.png'
3464Binary files images/conversation_incoming@27.png 1970-01-01 00:00:00 +0000 and images/conversation_incoming@27.png 2014-10-11 18:44:23 +0000 differ
3465=== added file 'images/conversation_incoming@27.sci'
3466--- images/conversation_incoming@27.sci 1970-01-01 00:00:00 +0000
3467+++ images/conversation_incoming@27.sci 2014-10-11 18:44:23 +0000
3468@@ -0,0 +1,5 @@
3469+border.left: 63
3470+border.top: 46
3471+border.bottom: 88
3472+border.right: 44
3473+source: conversation_incoming@27.png
3474
3475=== added file 'images/conversation_outgoing@27.png'
3476Binary files images/conversation_outgoing@27.png 1970-01-01 00:00:00 +0000 and images/conversation_outgoing@27.png 2014-10-11 18:44:23 +0000 differ
3477=== added file 'images/conversation_outgoing@27.sci'
3478--- images/conversation_outgoing@27.sci 1970-01-01 00:00:00 +0000
3479+++ images/conversation_outgoing@27.sci 2014-10-11 18:44:23 +0000
3480@@ -0,0 +1,5 @@
3481+border.left: 36
3482+border.top: 38
3483+border.bottom: 80
3484+border.right: 50
3485+source: conversation_outgoing@27.png
3486
3487=== added file 'images/dialog_clock_w.png'
3488Binary files images/dialog_clock_w.png 1970-01-01 00:00:00 +0000 and images/dialog_clock_w.png 2014-10-11 18:44:23 +0000 differ
3489=== added file 'images/dialogs_check.png'
3490Binary files images/dialogs_check.png 1970-01-01 00:00:00 +0000 and images/dialogs_check.png 2014-10-11 18:44:23 +0000 differ
3491=== added file 'images/dialogs_halfcheck.png'
3492Binary files images/dialogs_halfcheck.png 1970-01-01 00:00:00 +0000 and images/dialogs_halfcheck.png 2014-10-11 18:44:23 +0000 differ
3493=== added file 'images/group_aqua.png'
3494Binary files images/group_aqua.png 1970-01-01 00:00:00 +0000 and images/group_aqua.png 2014-10-11 18:44:23 +0000 differ
3495=== added file 'images/group_blue.png'
3496Binary files images/group_blue.png 1970-01-01 00:00:00 +0000 and images/group_blue.png 2014-10-11 18:44:23 +0000 differ
3497=== added file 'images/group_green.png'
3498Binary files images/group_green.png 1970-01-01 00:00:00 +0000 and images/group_green.png 2014-10-11 18:44:23 +0000 differ
3499=== added file 'images/group_orange.png'
3500Binary files images/group_orange.png 1970-01-01 00:00:00 +0000 and images/group_orange.png 2014-10-11 18:44:23 +0000 differ
3501=== added file 'images/group_pink.png'
3502Binary files images/group_pink.png 1970-01-01 00:00:00 +0000 and images/group_pink.png 2014-10-11 18:44:23 +0000 differ
3503=== added file 'images/group_red.png'
3504Binary files images/group_red.png 1970-01-01 00:00:00 +0000 and images/group_red.png 2014-10-11 18:44:23 +0000 differ
3505=== added file 'images/group_violet.png'
3506Binary files images/group_violet.png 1970-01-01 00:00:00 +0000 and images/group_violet.png 2014-10-11 18:44:23 +0000 differ
3507=== added file 'images/group_yellow.png'
3508Binary files images/group_yellow.png 1970-01-01 00:00:00 +0000 and images/group_yellow.png 2014-10-11 18:44:23 +0000 differ
3509=== added file 'images/grouplist.png'
3510Binary files images/grouplist.png 1970-01-01 00:00:00 +0000 and images/grouplist.png 2014-10-11 18:44:23 +0000 differ
3511=== added file 'images/ic_ab_logo.png'
3512Binary files images/ic_ab_logo.png 1970-01-01 00:00:00 +0000 and images/ic_ab_logo.png 2014-10-11 18:44:23 +0000 differ
3513=== added file 'images/ic_profile_send_message.png'
3514Binary files images/ic_profile_send_message.png 1970-01-01 00:00:00 +0000 and images/ic_profile_send_message.png 2014-10-11 18:44:23 +0000 differ
3515=== added file 'images/ic_send.png'
3516Binary files images/ic_send.png 1970-01-01 00:00:00 +0000 and images/ic_send.png 2014-10-11 18:44:23 +0000 differ
3517=== added file 'images/ic_send_disabled.png'
3518Binary files images/ic_send_disabled.png 1970-01-01 00:00:00 +0000 and images/ic_send_disabled.png 2014-10-11 18:44:23 +0000 differ
3519=== added file 'images/intro0.png'
3520Binary files images/intro0.png 1970-01-01 00:00:00 +0000 and images/intro0.png 2014-10-11 18:44:23 +0000 differ
3521=== added file 'images/intro1.png'
3522Binary files images/intro1.png 1970-01-01 00:00:00 +0000 and images/intro1.png 2014-10-11 18:44:23 +0000 differ
3523=== added file 'images/intro2.png'
3524Binary files images/intro2.png 1970-01-01 00:00:00 +0000 and images/intro2.png 2014-10-11 18:44:23 +0000 differ
3525=== added file 'images/intro3.png'
3526Binary files images/intro3.png 1970-01-01 00:00:00 +0000 and images/intro3.png 2014-10-11 18:44:23 +0000 differ
3527=== added file 'images/intro4.png'
3528Binary files images/intro4.png 1970-01-01 00:00:00 +0000 and images/intro4.png 2014-10-11 18:44:23 +0000 differ
3529=== added file 'images/intro5.png'
3530Binary files images/intro5.png 1970-01-01 00:00:00 +0000 and images/intro5.png 2014-10-11 18:44:23 +0000 differ
3531=== added file 'images/intro6.png'
3532Binary files images/intro6.png 1970-01-01 00:00:00 +0000 and images/intro6.png 2014-10-11 18:44:23 +0000 differ
3533=== added file 'images/telegram.png'
3534Binary files images/telegram.png 1970-01-01 00:00:00 +0000 and images/telegram.png 2014-10-11 18:44:23 +0000 differ
3535=== added file 'images/telegram.svg'
3536--- images/telegram.svg 1970-01-01 00:00:00 +0000
3537+++ images/telegram.svg 2014-10-11 18:44:23 +0000
3538@@ -0,0 +1,198 @@
3539+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
3540+<!-- Created with Inkscape (http://www.inkscape.org/) -->
3541+
3542+<svg
3543+ xmlns:dc="http://purl.org/dc/elements/1.1/"
3544+ xmlns:cc="http://creativecommons.org/ns#"
3545+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
3546+ xmlns:svg="http://www.w3.org/2000/svg"
3547+ xmlns="http://www.w3.org/2000/svg"
3548+ xmlns:xlink="http://www.w3.org/1999/xlink"
3549+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
3550+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
3551+ id="svg2"
3552+ version="1.1"
3553+ inkscape:version="0.48.4 r9939"
3554+ width="240"
3555+ height="240"
3556+ sodipodi:docname="telegram.svg">
3557+ <metadata
3558+ id="metadata8">
3559+ <rdf:RDF>
3560+ <cc:Work
3561+ rdf:about="">
3562+ <dc:format>image/svg+xml</dc:format>
3563+ <dc:type
3564+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
3565+ <dc:title />
3566+ </cc:Work>
3567+ </rdf:RDF>
3568+ </metadata>
3569+ <defs
3570+ id="defs6">
3571+ <linearGradient
3572+ id="linearGradient3877">
3573+ <stop
3574+ style="stop-color:#eff7fc;stop-opacity:1;"
3575+ offset="0"
3576+ id="stop3879" />
3577+ <stop
3578+ style="stop-color:#ffffff;stop-opacity:1;"
3579+ offset="1"
3580+ id="stop3881" />
3581+ </linearGradient>
3582+ <linearGradient
3583+ id="linearGradient3829">
3584+ <stop
3585+ id="stop3831"
3586+ offset="0"
3587+ style="stop-color:#1f96d4;stop-opacity:1;" />
3588+ <stop
3589+ id="stop3833"
3590+ offset="1"
3591+ style="stop-color:#37aee2;stop-opacity:1;" />
3592+ </linearGradient>
3593+ <linearGradient
3594+ id="linearGradient3821">
3595+ <stop
3596+ style="stop-color:#37aee2;stop-opacity:1;"
3597+ offset="0"
3598+ id="stop3823" />
3599+ <stop
3600+ style="stop-color:#1e96c8;stop-opacity:1;"
3601+ offset="1"
3602+ id="stop3825" />
3603+ </linearGradient>
3604+ <linearGradient
3605+ id="linearGradient3783">
3606+ <stop
3607+ style="stop-color:#1e94d3;stop-opacity:1;"
3608+ offset="0"
3609+ id="stop3785" />
3610+ <stop
3611+ id="stop3803"
3612+ offset="1"
3613+ style="stop-color:#1e94d3;stop-opacity:1;" />
3614+ </linearGradient>
3615+ <linearGradient
3616+ inkscape:collect="always"
3617+ xlink:href="#linearGradient3783"
3618+ id="linearGradient3827"
3619+ x1="-10"
3620+ y1="90"
3621+ x2="30"
3622+ y2="50"
3623+ gradientUnits="userSpaceOnUse" />
3624+ <linearGradient
3625+ inkscape:collect="always"
3626+ xlink:href="#linearGradient3783-1"
3627+ id="linearGradient3827-7"
3628+ x1="-10"
3629+ y1="90"
3630+ x2="30"
3631+ y2="50"
3632+ gradientUnits="userSpaceOnUse" />
3633+ <linearGradient
3634+ id="linearGradient3783-1">
3635+ <stop
3636+ style="stop-color:#1e94d3;stop-opacity:1;"
3637+ offset="0"
3638+ id="stop3785-2" />
3639+ <stop
3640+ id="stop3803-6"
3641+ offset="1"
3642+ style="stop-color:#1e94d3;stop-opacity:1;" />
3643+ </linearGradient>
3644+ <linearGradient
3645+ inkscape:collect="always"
3646+ xlink:href="#linearGradient3821"
3647+ id="linearGradient3873"
3648+ x1="16.5"
3649+ y1="56.333336"
3650+ x2="6.6666665"
3651+ y2="80"
3652+ gradientUnits="userSpaceOnUse" />
3653+ <linearGradient
3654+ inkscape:collect="always"
3655+ xlink:href="#linearGradient3877"
3656+ id="linearGradient3883"
3657+ x1="135"
3658+ y1="120"
3659+ x2="160"
3660+ y2="160"
3661+ gradientUnits="userSpaceOnUse" />
3662+ <linearGradient
3663+ inkscape:collect="always"
3664+ xlink:href="#linearGradient3821"
3665+ id="linearGradient3784"
3666+ x1="135.63235"
3667+ y1="23.727272"
3668+ x2="84.762161"
3669+ y2="98.296661"
3670+ gradientUnits="userSpaceOnUse"
3671+ gradientTransform="matrix(1.1616826,0,0,1.8835888,1.6670629,-2.6299072)" />
3672+ <linearGradient
3673+ inkscape:collect="always"
3674+ xlink:href="#linearGradient3821"
3675+ id="linearGradient3816"
3676+ gradientUnits="userSpaceOnUse"
3677+ gradientTransform="matrix(1.2526644,0,0,2.0706894,-9.6396796,-12.768958)"
3678+ x1="135.63235"
3679+ y1="23.727272"
3680+ x2="84.762161"
3681+ y2="98.296661" />
3682+ </defs>
3683+ <sodipodi:namedview
3684+ pagecolor="#ffffff"
3685+ bordercolor="#666666"
3686+ borderopacity="1"
3687+ objecttolerance="10"
3688+ gridtolerance="10"
3689+ guidetolerance="10"
3690+ inkscape:pageopacity="0"
3691+ inkscape:pageshadow="2"
3692+ inkscape:window-width="2505"
3693+ inkscape:window-height="1056"
3694+ id="namedview4"
3695+ showgrid="false"
3696+ inkscape:zoom="1.4142136"
3697+ inkscape:cx="347.12744"
3698+ inkscape:cy="20.202031"
3699+ inkscape:window-x="55"
3700+ inkscape:window-y="1033"
3701+ inkscape:window-maximized="1"
3702+ inkscape:current-layer="svg2">
3703+ <inkscape:grid
3704+ type="xygrid"
3705+ id="grid2987"
3706+ empspacing="5"
3707+ visible="true"
3708+ enabled="true"
3709+ snapvisiblegridlinesonly="true" />
3710+ </sodipodi:namedview>
3711+ <rect
3712+ style="fill:url(#linearGradient3816);fill-opacity:1"
3713+ id="rect3775"
3714+ width="240"
3715+ height="240"
3716+ x="-1.2397766e-05"
3717+ y="1.4305115e-06" />
3718+ <path
3719+ style="fill:#c8daea;fill-opacity:1;stroke:none"
3720+ d="m 98,175 c -3.887644,0 -3.226996,-1.46793 -4.567796,-5.16949 l -11.440678,-37.62712 70.805084,-44.237289 8.26271,2.161017 -6.8644,18.813562 z"
3721+ id="path2993"
3722+ inkscape:connector-curvature="0"
3723+ sodipodi:nodetypes="ccccccc" />
3724+ <path
3725+ style="fill:#a9c9dd;fill-opacity:1;stroke:none"
3726+ d="m 98,175 c 3,0 4.32989,-1.36747 6,-3 2.57835,-2.52034 36,-35 36,-35 l -20.47193,-4.95511 -19,12 L 98,174 z"
3727+ id="path2989"
3728+ inkscape:connector-curvature="0"
3729+ sodipodi:nodetypes="csccccc" />
3730+ <path
3731+ style="fill:url(#linearGradient3883);stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;fill-opacity:1"
3732+ d="m 100.04237,144.40678 48.36017,35.72884 c 5.51851,3.04487 9.5014,1.46836 10.87626,-5.12353 l 19.68513,-92.762819 c 2.01542,-8.080226 -3.08008,-11.745195 -8.35944,-9.348192 L 55.010511,117.48476 c -7.890082,3.1647 -7.844107,7.56662 -1.438184,9.52797 l 29.662531,9.2583 68.673252,-43.325271 c 3.24187,-1.965881 6.21727,-0.908988 3.77523,1.25841 z"
3733+ id="path2991"
3734+ inkscape:connector-curvature="0"
3735+ sodipodi:nodetypes="ccccccccccc" />
3736+</svg>
3737
3738=== added file 'images/telegram_symbolic.svg'
3739--- images/telegram_symbolic.svg 1970-01-01 00:00:00 +0000
3740+++ images/telegram_symbolic.svg 2014-10-11 18:44:23 +0000
3741@@ -0,0 +1,192 @@
3742+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
3743+<!-- Created with Inkscape (http://www.inkscape.org/) -->
3744+
3745+<svg
3746+ xmlns:dc="http://purl.org/dc/elements/1.1/"
3747+ xmlns:cc="http://creativecommons.org/ns#"
3748+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
3749+ xmlns:svg="http://www.w3.org/2000/svg"
3750+ xmlns="http://www.w3.org/2000/svg"
3751+ xmlns:xlink="http://www.w3.org/1999/xlink"
3752+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
3753+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
3754+ id="svg2"
3755+ version="1.1"
3756+ inkscape:version="0.48.5 r10040"
3757+ width="240"
3758+ height="240"
3759+ sodipodi:docname="telegram_symbolic.svg">
3760+ <metadata
3761+ id="metadata8">
3762+ <rdf:RDF>
3763+ <cc:Work
3764+ rdf:about="">
3765+ <dc:format>image/svg+xml</dc:format>
3766+ <dc:type
3767+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
3768+ <dc:title />
3769+ </cc:Work>
3770+ </rdf:RDF>
3771+ </metadata>
3772+ <defs
3773+ id="defs6">
3774+ <linearGradient
3775+ id="linearGradient3877">
3776+ <stop
3777+ style="stop-color:#eff7fc;stop-opacity:1;"
3778+ offset="0"
3779+ id="stop3879" />
3780+ <stop
3781+ style="stop-color:#ffffff;stop-opacity:1;"
3782+ offset="1"
3783+ id="stop3881" />
3784+ </linearGradient>
3785+ <linearGradient
3786+ id="linearGradient3829">
3787+ <stop
3788+ id="stop3831"
3789+ offset="0"
3790+ style="stop-color:#1f96d4;stop-opacity:1;" />
3791+ <stop
3792+ id="stop3833"
3793+ offset="1"
3794+ style="stop-color:#37aee2;stop-opacity:1;" />
3795+ </linearGradient>
3796+ <linearGradient
3797+ id="linearGradient3821">
3798+ <stop
3799+ style="stop-color:#37aee2;stop-opacity:1;"
3800+ offset="0"
3801+ id="stop3823" />
3802+ <stop
3803+ style="stop-color:#1e96c8;stop-opacity:1;"
3804+ offset="1"
3805+ id="stop3825" />
3806+ </linearGradient>
3807+ <linearGradient
3808+ id="linearGradient3783">
3809+ <stop
3810+ style="stop-color:#1e94d3;stop-opacity:1;"
3811+ offset="0"
3812+ id="stop3785" />
3813+ <stop
3814+ id="stop3803"
3815+ offset="1"
3816+ style="stop-color:#1e94d3;stop-opacity:1;" />
3817+ </linearGradient>
3818+ <linearGradient
3819+ inkscape:collect="always"
3820+ xlink:href="#linearGradient3783"
3821+ id="linearGradient3827"
3822+ x1="-10"
3823+ y1="90"
3824+ x2="30"
3825+ y2="50"
3826+ gradientUnits="userSpaceOnUse" />
3827+ <linearGradient
3828+ inkscape:collect="always"
3829+ xlink:href="#linearGradient3783-1"
3830+ id="linearGradient3827-7"
3831+ x1="-10"
3832+ y1="90"
3833+ x2="30"
3834+ y2="50"
3835+ gradientUnits="userSpaceOnUse" />
3836+ <linearGradient
3837+ id="linearGradient3783-1">
3838+ <stop
3839+ style="stop-color:#1e94d3;stop-opacity:1;"
3840+ offset="0"
3841+ id="stop3785-2" />
3842+ <stop
3843+ id="stop3803-6"
3844+ offset="1"
3845+ style="stop-color:#1e94d3;stop-opacity:1;" />
3846+ </linearGradient>
3847+ <linearGradient
3848+ inkscape:collect="always"
3849+ xlink:href="#linearGradient3821"
3850+ id="linearGradient3873"
3851+ x1="16.5"
3852+ y1="56.333336"
3853+ x2="6.6666665"
3854+ y2="80"
3855+ gradientUnits="userSpaceOnUse" />
3856+ <linearGradient
3857+ inkscape:collect="always"
3858+ xlink:href="#linearGradient3877"
3859+ id="linearGradient3883"
3860+ x1="135"
3861+ y1="120"
3862+ x2="160"
3863+ y2="160"
3864+ gradientUnits="userSpaceOnUse"
3865+ gradientTransform="matrix(1.8182052,0,0,2.1564431,-86.693748,-153.47211)" />
3866+ <linearGradient
3867+ inkscape:collect="always"
3868+ xlink:href="#linearGradient3821"
3869+ id="linearGradient3784"
3870+ x1="135.63235"
3871+ y1="23.727272"
3872+ x2="84.762161"
3873+ y2="98.296661"
3874+ gradientUnits="userSpaceOnUse"
3875+ gradientTransform="matrix(1.1616826,0,0,1.8835888,1.6670629,-2.6299072)" />
3876+ <linearGradient
3877+ inkscape:collect="always"
3878+ xlink:href="#linearGradient3821"
3879+ id="linearGradient3816"
3880+ gradientUnits="userSpaceOnUse"
3881+ gradientTransform="matrix(1.2526644,0,0,2.0706894,-9.6396796,-12.768958)"
3882+ x1="135.63235"
3883+ y1="23.727272"
3884+ x2="84.762161"
3885+ y2="98.296661" />
3886+ </defs>
3887+ <sodipodi:namedview
3888+ pagecolor="#ffffff"
3889+ bordercolor="#666666"
3890+ borderopacity="1"
3891+ objecttolerance="10"
3892+ gridtolerance="10"
3893+ guidetolerance="10"
3894+ inkscape:pageopacity="0"
3895+ inkscape:pageshadow="2"
3896+ inkscape:window-width="1920"
3897+ inkscape:window-height="1056"
3898+ id="namedview4"
3899+ showgrid="false"
3900+ inkscape:zoom="1.4142136"
3901+ inkscape:cx="347.12744"
3902+ inkscape:cy="20.202031"
3903+ inkscape:window-x="0"
3904+ inkscape:window-y="24"
3905+ inkscape:window-maximized="1"
3906+ inkscape:current-layer="svg2">
3907+ <inkscape:grid
3908+ type="xygrid"
3909+ id="grid2987"
3910+ empspacing="5"
3911+ visible="true"
3912+ enabled="true"
3913+ snapvisiblegridlinesonly="true" />
3914+ </sodipodi:namedview>
3915+ <path
3916+ style="fill:#c8daea;fill-opacity:1;stroke:none"
3917+ d="m 91.490364,223.90544 c -7.068542,0 -5.867348,-3.1655 -8.3052,-11.14771 L 62.383669,131.61698 191.12184,36.221787 l 15.0233,4.66011 -12.48089,40.570376 z"
3918+ id="path2993"
3919+ inkscape:connector-curvature="0"
3920+ sodipodi:nodetypes="ccccccc" />
3921+ <path
3922+ style="fill:#a9c9dd;fill-opacity:1;stroke:none"
3923+ d="m 91.490364,223.90544 c 5.454604,0 7.872619,-2.94887 10.909226,-6.46934 4.68796,-5.43497 65.45539,-75.4755 65.45539,-75.4755 l -37.22217,-10.68541 -34.545901,25.87731 -4.596545,64.59649 z"
3924+ id="path2989"
3925+ inkscape:connector-curvature="0"
3926+ sodipodi:nodetypes="csccccc" />
3927+ <path
3928+ style="fill:url(#linearGradient3883);fill-opacity:1;stroke:none"
3929+ d="m 95.203812,157.93289 87.928708,77.04721 c 10.03378,6.56609 17.27549,3.16644 19.77527,-11.04859 L 238.6994,23.893767 C 242.36384,6.4692194 233.09918,-1.434078 223.50022,3.7349231 L 13.326647,99.877089 C -1.0191403,106.70159 -0.93554896,116.19407 10.711735,120.42362 L 64.644301,140.38861 189.50637,46.960141 c 5.89438,-4.239313 11.30427,-1.960188 6.86414,2.713683 z"
3930+ id="path2991"
3931+ inkscape:connector-curvature="0"
3932+ sodipodi:nodetypes="ccccccccccc" />
3933+</svg>
3934
3935=== added file 'images/user_aqua.png'
3936Binary files images/user_aqua.png 1970-01-01 00:00:00 +0000 and images/user_aqua.png 2014-10-11 18:44:23 +0000 differ
3937=== added file 'images/user_blue.png'
3938Binary files images/user_blue.png 1970-01-01 00:00:00 +0000 and images/user_blue.png 2014-10-11 18:44:23 +0000 differ
3939=== added file 'images/user_green.png'
3940Binary files images/user_green.png 1970-01-01 00:00:00 +0000 and images/user_green.png 2014-10-11 18:44:23 +0000 differ
3941=== added file 'images/user_orange.png'
3942Binary files images/user_orange.png 1970-01-01 00:00:00 +0000 and images/user_orange.png 2014-10-11 18:44:23 +0000 differ
3943=== added file 'images/user_pink.png'
3944Binary files images/user_pink.png 1970-01-01 00:00:00 +0000 and images/user_pink.png 2014-10-11 18:44:23 +0000 differ
3945=== added file 'images/user_placeholder.png'
3946Binary files images/user_placeholder.png 1970-01-01 00:00:00 +0000 and images/user_placeholder.png 2014-10-11 18:44:23 +0000 differ
3947=== added file 'images/user_red.png'
3948Binary files images/user_red.png 1970-01-01 00:00:00 +0000 and images/user_red.png 2014-10-11 18:44:23 +0000 differ
3949=== added file 'images/user_violet.png'
3950Binary files images/user_violet.png 1970-01-01 00:00:00 +0000 and images/user_violet.png 2014-10-11 18:44:23 +0000 differ
3951=== added file 'images/user_yellow.png'
3952Binary files images/user_yellow.png 1970-01-01 00:00:00 +0000 and images/user_yellow.png 2014-10-11 18:44:23 +0000 differ
3953=== added directory 'js'
3954=== added file 'js/avatar.js'
3955--- js/avatar.js 1970-01-01 00:00:00 +0000
3956+++ js/avatar.js 2014-10-11 18:44:23 +0000
3957@@ -0,0 +1,21 @@
3958+.pragma library
3959+
3960+var AVATARS = [
3961+ ["#8179d7", "user_violet.png"],
3962+ ["#f2749a", "user_pink.png" ],
3963+ ["#7ec455", "user_green.png" ],
3964+ ["#f3c34a", "user_yellow.png"],
3965+ ["#5b9dd8", "user_blue.png" ],
3966+ ["#62b8cd", "user_aqua.png" ],
3967+ ["#ed8b4a", "user_orange.png"],
3968+ ["#d95848", "user_red.png" ]
3969+]
3970+
3971+function getColor(userId) {
3972+ return AVATARS[userId % 8][0];
3973+}
3974+
3975+function getAvatar(userId) {
3976+ return AVATARS[userId % 8][1];
3977+}
3978+
3979
3980=== added file 'js/ba-linkify.js'
3981--- js/ba-linkify.js 1970-01-01 00:00:00 +0000
3982+++ js/ba-linkify.js 2014-10-11 18:44:23 +0000
3983@@ -0,0 +1,211 @@
3984+/*!
3985+ * JavaScript Linkify - v0.3 - 6/27/2009
3986+ * http://benalman.com/projects/javascript-linkify/
3987+ *
3988+ * Copyright (c) 2009 "Cowboy" Ben Alman
3989+ * Dual licensed under the MIT and GPL licenses.
3990+ * http://benalman.com/about/license/
3991+ *
3992+ * Some regexps adapted from http://userscripts.org/scripts/review/7122
3993+ */
3994+
3995+// Script: JavaScript Linkify: Process links in text!
3996+//
3997+// *Version: 0.3, Last updated: 6/27/2009*
3998+//
3999+// Project Home - http://benalman.com/projects/javascript-linkify/
4000+// GitHub - http://github.com/cowboy/javascript-linkify/
4001+// Source - http://github.com/cowboy/javascript-linkify/raw/master/ba-linkify.js
4002+// (Minified) - http://github.com/cowboy/javascript-linkify/raw/master/ba-linkify.min.js (2.8kb)
4003+//
4004+// About: License
4005+//
4006+// Copyright (c) 2009 "Cowboy" Ben Alman,
4007+// Dual licensed under the MIT and GPL licenses.
4008+// http://benalman.com/about/license/
4009+//
4010+// About: Examples
4011+//
4012+// This working example, complete with fully commented code, illustrates one way
4013+// in which this code can be used.
4014+//
4015+// Linkify - http://benalman.com/code/projects/javascript-linkify/examples/linkify/
4016+//
4017+// About: Support and Testing
4018+//
4019+// Information about what browsers this code has been tested in.
4020+//
4021+// Browsers Tested - Internet Explorer 6-8, Firefox 2-3.7, Safari 3-4, Chrome, Opera 9.6-10.
4022+//
4023+// About: Release History
4024+//
4025+// 0.3 - (6/27/2009) Initial release
4026+
4027+// Function: linkify
4028+//
4029+// Turn text into linkified html.
4030+//
4031+// Usage:
4032+//
4033+// > var html = linkify( text [, options ] );
4034+//
4035+// Arguments:
4036+//
4037+// text - (String) Non-HTML text containing links to be parsed.
4038+// options - (Object) An optional object containing linkify parse options.
4039+//
4040+// Options:
4041+//
4042+// callback (Function) - If specified, this will be called once for each link-
4043+// or non-link-chunk with two arguments, text and href. If the chunk is
4044+// non-link, href will be omitted. If unspecified, the default linkification
4045+// callback is used.
4046+// punct_regexp (RegExp) - A RegExp that will be used to trim trailing
4047+// punctuation from links, instead of the default. If set to null, trailing
4048+// punctuation will not be trimmed.
4049+//
4050+// Returns:
4051+//
4052+// (String) An HTML string containing links.
4053+
4054+var SCHEME = "[a-z\\d.-]+://",
4055+IPV4 = "(?:(?:[0-9]|[1-9]\\d|1\\d{2}|2[0-4]\\d|25[0-5])\\.){3}(?:[0-9]|[1-9]\\d|1\\d{2}|2[0-4]\\d|25[0-5])",
4056+HOSTNAME = "(?:(?:[^\\s!@#$%^&*()_=+[\\]{}\\\\|;:'\",.<>/?]+)\\.)+",
4057+TLD = "(?:ac|ad|aero|ae|af|ag|ai|al|am|an|ao|aq|arpa|ar|asia|as|at|au|aw|ax|az|ba|bb|bd|be|bf|bg|bh|biz|bi|bj|bm|bn|bo|br|bs|bt|bv|bw|by|bz|cat|ca|cc|cd|cf|cg|ch|ci|ck|cl|cm|cn|coop|com|co|cr|cu|cv|cx|cy|cz|de|dj|dk|dm|do|dz|ec|edu|ee|eg|er|es|et|eu|fi|fj|fk|fm|fo|fr|ga|gb|gd|ge|gf|gg|gh|gi|gl|gm|gn|gov|gp|gq|gr|gs|gt|gu|gw|gy|hk|hm|hn|hr|ht|hu|id|ie|il|im|info|int|in|io|iq|ir|is|it|je|jm|jobs|jo|jp|ke|kg|kh|ki|km|kn|kp|kr|kw|ky|kz|la|lb|lc|li|lk|lr|ls|lt|lu|lv|ly|ma|mc|md|me|mg|mh|mil|mk|ml|mm|mn|mobi|mo|mp|mq|mr|ms|mt|museum|mu|mv|mw|mx|my|mz|name|na|nc|net|ne|nf|ng|ni|nl|no|np|nr|nu|nz|om|org|pa|pe|pf|pg|ph|pk|pl|pm|pn|pro|pr|ps|pt|pw|py|qa|re|ro|rs|ru|rw|sa|sb|sc|sd|se|sg|sh|si|sj|sk|sl|sm|sn|so|sr|st|su|sv|sy|sz|tc|td|tel|tf|tg|th|tj|tk|tl|tm|tn|to|tp|travel|tr|tt|tv|tw|tz|ua|ug|uk|um|us|uy|uz|va|vc|ve|vg|vi|vn|vu|wf|ws|xn--0zwm56d|xn--11b5bs3a9aj6g|xn--80akhbyknj4f|xn--9t4b11yi5a|xn--deba0ad|xn--g6w251d|xn--hgbk6aj7f53bba|xn--hlcj6aya9esc7a|xn--jxalpdlp|xn--kgbechtv|xn--zckzah|ye|yt|yu|za|zm|zw)",
4058+HOST_OR_IP = "(?:" + HOSTNAME + TLD + "|" + IPV4 + ")",
4059+PATH = "(?:[;/][^#?<>\\s]*)?",
4060+QUERY_FRAG = "(?:\\?[^#<>\\s]*)?(?:#[^<>\\s]*)?",
4061+URI1 = "\\b" + SCHEME + "[^<>\\s]+",
4062+URI2 = "\\b" + HOST_OR_IP + PATH + QUERY_FRAG + "(?!\\w)",
4063+
4064+MAILTO = "mailto:",
4065+EMAIL = "(?:" + MAILTO + ")?[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@" + HOST_OR_IP + QUERY_FRAG + "(?!\\w)",
4066+
4067+URI_RE = new RegExp( "(?:" + URI1 + "|" + URI2 + "|" + EMAIL + ")", "ig" ),
4068+SCHEME_RE = new RegExp( "^" + SCHEME, "i" ),
4069+
4070+quotes = {
4071+ "'": "`",
4072+ '>': '<',
4073+ ')': '(',
4074+ ']': '[',
4075+ '}': '{',
4076+ '»': '«',
4077+ '›': '‹'
4078+},
4079+
4080+default_options = {
4081+ callback: function( text, href ) {
4082+ return href ? '<a href="' + href + '" title="' + href + '">' + text + '</a>' : text;
4083+ },
4084+ punct_regexp: /(?:[!?.,:;'"]|(?:&|&amp;)(?:lt|gt|quot|apos|raquo|laquo|rsaquo|lsaquo);)$/
4085+};
4086+
4087+function linkify( txt, options ) {
4088+ options = options || {};
4089+
4090+ // Temp variables.
4091+ var arr,
4092+ i,
4093+ link,
4094+ href,
4095+
4096+ // Output HTML.
4097+ html = '',
4098+
4099+ // Store text / link parts, in order, for re-combination.
4100+ parts = [],
4101+
4102+ // Used for keeping track of indices in the text.
4103+ idx_prev,
4104+ idx_last,
4105+ idx,
4106+ link_last,
4107+
4108+ // Used for trimming trailing punctuation and quotes from links.
4109+ matches_begin,
4110+ matches_end,
4111+ quote_begin,
4112+ quote_end;
4113+
4114+ // Initialize options.
4115+ for ( i in default_options ) {
4116+ if ( options[ i ] === undefined ) {
4117+ options[ i ] = default_options[ i ];
4118+ }
4119+ }
4120+
4121+ // Find links.
4122+ while ( arr = URI_RE.exec( txt ) ) {
4123+
4124+ link = arr[0];
4125+ idx_last = URI_RE.lastIndex;
4126+ idx = idx_last - link.length;
4127+
4128+ // Not a link if preceded by certain characters.
4129+ if ( /[\/:]/.test( txt.charAt( idx - 1 ) ) ) {
4130+ continue;
4131+ }
4132+
4133+ // Trim trailing punctuation.
4134+ do {
4135+ // If no changes are made, we don't want to loop forever!
4136+ link_last = link;
4137+
4138+ quote_end = link.substr( -1 )
4139+ quote_begin = quotes[ quote_end ];
4140+
4141+ // Ending quote character?
4142+ if ( quote_begin ) {
4143+ matches_begin = link.match( new RegExp( '\\' + quote_begin + '(?!$)', 'g' ) );
4144+ matches_end = link.match( new RegExp( '\\' + quote_end, 'g' ) );
4145+
4146+ // If quotes are unbalanced, remove trailing quote character.
4147+ if ( ( matches_begin ? matches_begin.length : 0 ) < ( matches_end ? matches_end.length : 0 ) ) {
4148+ link = link.substr( 0, link.length - 1 );
4149+ idx_last--;
4150+ }
4151+ }
4152+
4153+ // Ending non-quote punctuation character?
4154+ if ( options.punct_regexp ) {
4155+ link = link.replace( options.punct_regexp, function(a){
4156+ idx_last -= a.length;
4157+ return '';
4158+ });
4159+ }
4160+ } while ( link.length && link !== link_last );
4161+
4162+ href = link;
4163+
4164+ // Add appropriate protocol to naked links.
4165+ if ( !SCHEME_RE.test( href ) ) {
4166+ href = ( href.indexOf( '@' ) !== -1 ? ( !href.indexOf( MAILTO ) ? '' : MAILTO )
4167+ : !href.indexOf( 'irc.' ) ? 'irc://'
4168+ : !href.indexOf( 'ftp.' ) ? 'ftp://'
4169+ : 'http://' )
4170+ + href;
4171+ }
4172+
4173+ // Push preceding non-link text onto the array.
4174+ if ( idx_prev != idx ) {
4175+ parts.push([ txt.slice( idx_prev, idx ) ]);
4176+ idx_prev = idx_last;
4177+ }
4178+
4179+ // Push massaged link onto the array
4180+ parts.push([ link, href ]);
4181+ };
4182+
4183+ // Push remaining non-link text onto the array.
4184+ parts.push([ txt.substr( idx_prev ) ]);
4185+
4186+ // Process the array items.
4187+ for ( i = 0; i < parts.length; i++ ) {
4188+ html += options.callback.apply( this, parts[i] );
4189+ }
4190+
4191+ // In case of catastrophic failure, return the original text;
4192+ return html || txt;
4193+};
4194+
4195
4196=== added file 'js/time.js'
4197--- js/time.js 1970-01-01 00:00:00 +0000
4198+++ js/time.js 2014-10-11 18:44:23 +0000
4199@@ -0,0 +1,44 @@
4200+.pragma library
4201+
4202+var MILLIS_IN_DAY = 1000 * 60 * 60 * 24;
4203+var MILLIS_IN_WEEK = 7 * MILLIS_IN_DAY;
4204+
4205+function format(time) {
4206+ var date = new Date(time);
4207+ var today = new Date();
4208+
4209+ var isToday = date.getDate() === today.getDate();
4210+ if (isToday) {
4211+ return Qt.formatTime(date, "hh:mm");
4212+ } else {
4213+ var oneWeekAgo = new Date(today.getTime() - MILLIS_IN_WEEK);
4214+ var isLessThanWeek =
4215+ date.getTime() > oneWeekAgo.getTime() &&
4216+ date.getDate() !== oneWeekAgo.getDate();
4217+ if (isLessThanWeek) {
4218+ return Qt.formatDate(date, "ddd");
4219+ }
4220+ }
4221+ return Qt.formatDate(date, "MMM d");
4222+}
4223+
4224+function formatLastSeen(time) {
4225+ var date = new Date(time);
4226+ var today = new Date();
4227+ var yesterday = new Date(today - MILLIS_IN_DAY);
4228+
4229+ var isToday = date.getDate() === today.getDate();
4230+ if (isToday) {
4231+ return "today at " + Qt.formatTime(date, "hh:mm");
4232+ } else if (date.getDate() === yesterday.getDate()) {
4233+ return "yesterday at " + Qt.formatTime(date, "hh:mm");
4234+ } else {
4235+ return Qt.formatDate(date, "MMM d") + " at " + Qt.formatTime(date, "hh:mm");
4236+ }
4237+}
4238+
4239+function formatTimeOnly(time) {
4240+ var date = new Date(time);
4241+
4242+ return Qt.formatTime(date, "hh:mm");
4243+}
4244
4245=== added file 'manifest.json.in'
4246--- manifest.json.in 1970-01-01 00:00:00 +0000
4247+++ manifest.json.in 2014-10-11 18:44:23 +0000
4248@@ -0,0 +1,20 @@
4249+{
4250+ "name": "@APP_PACKAGE@",
4251+ "version": "@APP_VERSION@",
4252+ "description": "Telegram for Ubuntu",
4253+ "framework": "@FRAMEWORK@",
4254+ "architecture": "@ARCHITECTURE@",
4255+ "title": "@APP_TITLE@",
4256+ "hooks": {
4257+ "telegram": {
4258+ "apparmor": "apparmor-telegram.json",
4259+ "desktop": "telegram.desktop"
4260+ },
4261+ "push": {
4262+ "apparmor": "apparmor-push.json",
4263+ "push-helper": "push.json"
4264+ }
4265+ },
4266+ "icon": "@APP_ICON@",
4267+ "maintainer": "Ubuntu Telegram team <libqtelegram-team@lists.launchpad.net>"
4268+}
4269
4270=== added directory 'po'
4271=== added file 'po/CMakeLists.txt'
4272--- po/CMakeLists.txt 1970-01-01 00:00:00 +0000
4273+++ po/CMakeLists.txt 2014-10-11 18:44:23 +0000
4274@@ -0,0 +1,29 @@
4275+include(FindGettext)
4276+find_program(GETTEXT_XGETTEXT_EXECUTABLE xgettext)
4277+
4278+set(DOMAIN ${PROJECT_NAME})
4279+set(POT_FILE ${DOMAIN}.pot)
4280+file(GLOB PO_FILES *.po)
4281+
4282+add_custom_target(${POT_FILE} ALL
4283+ COMMENT "Generating translation template"
4284+ COMMAND ${INTLTOOL_EXTRACT} --update --type=gettext/ini
4285+ --srcdir=${CMAKE_SOURCE_DIR} ${DESKTOP_FILE}.in.in
4286+ COMMAND ${GETTEXT_XGETTEXT_EXECUTABLE} -o ${POT_FILE}
4287+ --from-code=UTF-8
4288+ --c++ --qt --add-comments=TRANSLATORS
4289+ --keyword=tr --keyword=tr:1,2 --keyword=N_
4290+ --package-name='${PROJECT}'
4291+ --copyright-holder='Canonical Ltd.'
4292+ -D ${CMAKE_CURRENT_SOURCE_DIR} ${I18N_SRC_FILES}
4293+ -D ${CMAKE_CURRENT_BINARY_DIR} ${DESKTOP_FILE}.in.in.h
4294+ COMMAND ${CMAKE_COMMAND} -E copy ${POT_FILE} ${CMAKE_CURRENT_SOURCE_DIR})
4295+
4296+foreach(PO_FILE ${PO_FILES})
4297+ get_filename_component(LANG ${PO_FILE} NAME_WE)
4298+ gettext_process_po_files(${LANG} ALL PO_FILES ${PO_FILE})
4299+ set(INSTALL_DIR ${CMAKE_INSTALL_LOCALEDIR}/${LANG}/LC_MESSAGES)
4300+ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${LANG}.gmo
4301+ DESTINATION ${INSTALL_DIR}
4302+ RENAME ${DOMAIN}.mo)
4303+endforeach(PO_FILE)
4304
4305=== added file 'po/ca.po'
4306--- po/ca.po 1970-01-01 00:00:00 +0000
4307+++ po/ca.po 2014-10-11 18:44:23 +0000
4308@@ -0,0 +1,403 @@
4309+# Catalan translation for libqtelegram
4310+# Copyright (c) 2014 Rosetta Contributors and Canonical Ltd 2014
4311+# This file is distributed under the same license as the libqtelegram package.
4312+# FIRST AUTHOR <EMAIL@ADDRESS>, 2014.
4313+#
4314+msgid ""
4315+msgstr ""
4316+"Project-Id-Version: libqtelegram\n"
4317+"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
4318+"POT-Creation-Date: 2014-10-07 12:34+0200\n"
4319+"PO-Revision-Date: 2014-10-01 06:18+0000\n"
4320+"Last-Translator: David Planella <david.planella@ubuntu.com>\n"
4321+"Language-Team: Catalan <ca@li.org>\n"
4322+"MIME-Version: 1.0\n"
4323+"Content-Type: text/plain; charset=UTF-8\n"
4324+"Content-Transfer-Encoding: 8bit\n"
4325+"X-Launchpad-Export-Date: 2014-10-08 08:27+0000\n"
4326+"X-Generator: Launchpad (build 17196)\n"
4327+
4328+#: ../components/TelegramContactsListItem.qml:61
4329+msgid "Contact"
4330+msgstr "Contacte"
4331+
4332+#: ../components/TelegramContactsListItem.qml:77
4333+msgid "Last seen"
4334+msgstr "Vist per darrera vegada"
4335+
4336+#: ../components/TelegramContactsListItem.qml:86 ../ui/AddContactPage.qml:219
4337+#: ../ui/ProfilePage.qml:29
4338+msgid "online"
4339+msgstr "en línia"
4340+
4341+#. TRANSLATORS: the argument refers to a time
4342+#: ../components/TelegramContactsListItem.qml:89 ../ui/AddContactPage.qml:222
4343+#: ../ui/ProfilePage.qml:32
4344+#, qt-format
4345+msgid "last seen %1"
4346+msgstr "vist a les %1"
4347+
4348+#: ../components/TelegramHeader.qml:60
4349+msgid "Connecting..."
4350+msgstr "S'està connectant..."
4351+
4352+#: ../components/TelegramHeader.qml:60 ../ui/ContactsPage.qml:272
4353+#: ../ui/SettingsPage.qml:50 ../ui/SettingsPage.qml:100
4354+#: telegram.desktop.in.in.h:1
4355+msgid "Telegram"
4356+msgstr "Telegram"
4357+
4358+#: ../components/TgButton.qml:9
4359+msgid "Next"
4360+msgstr ""
4361+
4362+#: ../library/uitest/ui/DialogDesignPage.qml:146
4363+msgid "Enter local path to send"
4364+msgstr "Introduïu el camí local per enviar"
4365+
4366+#: ../library/uitest/ui/DialogDesignPage.qml:153
4367+msgid "Enter msg to send"
4368+msgstr "Escriviu el missatge per enviar"
4369+
4370+#: ../library/uitest/ui/SignInPageDesign.qml:44
4371+msgid ""
4372+"Please enter your full phone \n"
4373+"number with country code"
4374+msgstr ""
4375+"Intoduïu el vostre número de telèfon\n"
4376+"complet amb el codi de país"
4377+
4378+#: ../library/uitest/ui/SignInPageDesign.qml:66
4379+msgid "with '+' sign"
4380+msgstr "amb el signe «»"
4381+
4382+#: ../library/uitest/ui/SignUpPageDesign.qml:44
4383+msgid ""
4384+"You are not registered yet.\n"
4385+"Please provide registration data"
4386+msgstr ""
4387+"Encara no esteu registrat.\n"
4388+"Heu d'introduir les dades de registre"
4389+
4390+#: ../library/uitest/ui/SignUpPageDesign.qml:66
4391+msgid "first name"
4392+msgstr "Nom"
4393+
4394+#: ../library/uitest/ui/SignUpPageDesign.qml:78
4395+msgid "last name"
4396+msgstr "Cognom"
4397+
4398+#: ../library/uitest/ui/VerificationCodePageDesign.qml:43
4399+msgid ""
4400+"We have sent you a code via SMS.\n"
4401+"Please enter it below\n"
4402+msgstr ""
4403+"Us hem enviat un codi a través d'un missatge de text.\n"
4404+"Introduïu-lo aquí sota\n"
4405+
4406+#: ../library/uitest/ui/VerificationCodePageDesign.qml:73
4407+msgid "Enter your code"
4408+msgstr "Introduïu el codi"
4409+
4410+#: ../library/uitest/uitest.qml:112 ../library/uitest/uitest.qml:120
4411+msgid "The code you have entered is not valid. Try again"
4412+msgstr "Heu introduït un codi que no és vàlid. Torneu-ho a provar"
4413+
4414+#: ../library/uitest/uitest.qml:140
4415+msgid "calling user's mobile"
4416+msgstr "s'està trucant al mòbil de l'usuari"
4417+
4418+#: ../telegram.qml:330
4419+msgid "Push notifications"
4420+msgstr "Notificacions"
4421+
4422+#: ../telegram.qml:331
4423+msgid "To enable push, sign in to your Ubuntu One account."
4424+msgstr ""
4425+"Heu d'entrar al compte de l'Ubuntu One per habilitar les notificacions"
4426+
4427+#: ../telegram.qml:333
4428+msgid "Sign in to Ubuntu One"
4429+msgstr "Entra a l'Ubuntu One"
4430+
4431+#: ../telegram.qml:342
4432+msgid "Remind me later"
4433+msgstr "Recorda-m'ho més endavant"
4434+
4435+#: ../telegram.qml:350
4436+msgid "Don't use push"
4437+msgstr "No utilitzis notificacions"
4438+
4439+#: ../ui/AddContactPage.qml:26 ../ui/ContactsPage.qml:242
4440+msgid "Add Contact"
4441+msgstr "Afegeix un contacte"
4442+
4443+#: ../ui/AddContactPage.qml:31 ../ui/SignInPage.qml:118
4444+msgid "Done"
4445+msgstr "Fet"
4446+
4447+#: ../ui/AddContactPage.qml:36 ../ui/ContactsPage.qml:260
4448+#: ../ui/ContactsPage.qml:298 ../ui/SettingsPage.qml:62
4449+#: ../ui/SettingsPage.qml:114
4450+msgid "Cancel"
4451+msgstr "Cancel·la"
4452+
4453+#: ../ui/AddContactPage.qml:84
4454+msgid "+1 1234 56789"
4455+msgstr "+1 1234 56789"
4456+
4457+#: ../ui/AddContactPage.qml:102
4458+msgid "last seen yesterday at 19:16"
4459+msgstr "vist per darrera vegada ahir a les 19:16"
4460+
4461+#: ../ui/AddContactPage.qml:122
4462+msgid "Phone number (required)"
4463+msgstr "Número de telèfon (requerit)"
4464+
4465+#: ../ui/AddContactPage.qml:139 ../ui/SignUpPage.qml:50
4466+msgid "First name (required)"
4467+msgstr "Nom (requerit)"
4468+
4469+#: ../ui/AddContactPage.qml:155 ../ui/SignUpPage.qml:63
4470+msgid "Last name (optional)"
4471+msgstr "Cognoms (opcionals)"
4472+
4473+#: ../ui/AddContactPage.qml:195
4474+msgid "Could not add contact"
4475+msgstr "No s'ha pogut afegir el contacte"
4476+
4477+#: ../ui/ContactsPage.qml:26 ../ui/ContactsPage.qml:33
4478+#: ../ui/DialogsPage.qml:19
4479+msgid "Search"
4480+msgstr "Cerca"
4481+
4482+#: ../ui/ContactsPage.qml:38
4483+msgid "Add"
4484+msgstr "Afegeix"
4485+
4486+#: ../ui/ContactsPage.qml:46
4487+msgid "Ok"
4488+msgstr "D'acord"
4489+
4490+#: ../ui/ContactsPage.qml:55
4491+msgid "New group chat"
4492+msgstr ""
4493+
4494+#: ../ui/ContactsPage.qml:57
4495+msgid "Add to group"
4496+msgstr ""
4497+
4498+#: ../ui/ContactsPage.qml:59 ../ui/DialogsPage.qml:37
4499+msgid "Contacts"
4500+msgstr "Contactes"
4501+
4502+#: ../ui/ContactsPage.qml:81
4503+msgid "No contacts"
4504+msgstr "Cap contacte"
4505+
4506+#: ../ui/ContactsPage.qml:115
4507+msgid "Chat title"
4508+msgstr "Títol de la conversa"
4509+
4510+#. TRANSLATORS: the first argument refers to the number of members
4511+#. on a group conversation. The second one refers to the maximum
4512+#. number of members that are supporte for groups (currently 200).
4513+#: ../ui/ContactsPage.qml:201
4514+#, qt-format
4515+msgid "%1/%2 members"
4516+msgstr "%1/%2 membres"
4517+
4518+#: ../ui/ContactsPage.qml:244
4519+msgid "From Address Book"
4520+msgstr "De la llibreta d'adreces"
4521+
4522+#: ../ui/ContactsPage.qml:252
4523+msgid "Enter Details"
4524+msgstr "Introduïu els detalls"
4525+
4526+#: ../ui/ContactsPage.qml:273
4527+msgid "Text"
4528+msgstr ""
4529+
4530+#: ../ui/ContactsPage.qml:288 ../ui/SettingsPage.qml:53
4531+#: ../ui/SettingsPage.qml:103
4532+msgid "OK"
4533+msgstr "D'acord"
4534+
4535+#: ../ui/ContactsPage.qml:304
4536+#, qt-format
4537+msgid ""
4538+"Add %1 to %2?\n"
4539+"\n"
4540+"Number of last messages to forward:"
4541+msgstr ""
4542+
4543+#: ../ui/DialogPage.qml:23
4544+msgid "Send picture"
4545+msgstr "Envia una imatge"
4546+
4547+#: ../ui/DialogPage.qml:30
4548+msgid "Profile Info"
4549+msgstr ""
4550+
4551+#: ../ui/DialogPage.qml:37
4552+msgid "Add member"
4553+msgstr ""
4554+
4555+#: ../ui/DialogPage.qml:83
4556+msgid "Add to contacts"
4557+msgstr "Afegeix als contactes"
4558+
4559+#: ../ui/DialogPage.qml:115
4560+msgid "Type message"
4561+msgstr "Escriviu un missatge"
4562+
4563+#: ../ui/DialogsPage.qml:25
4564+msgid "Compose"
4565+msgstr "Escriviu un missatge"
4566+
4567+#: ../ui/DialogsPage.qml:31
4568+msgid "New Group"
4569+msgstr "Grup nou"
4570+
4571+#: ../ui/DialogsPage.qml:42 ../ui/SettingsPage.qml:10
4572+#: ../ui/SettingsPage.qml:25
4573+msgid "Settings"
4574+msgstr "Paràmetres"
4575+
4576+#: ../ui/DialogsPage.qml:57
4577+msgid "No chats"
4578+msgstr "No hi ha converses"
4579+
4580+#: ../ui/DialogsPage.qml:90
4581+msgid "typing..."
4582+msgstr "escrivint..."
4583+
4584+#: ../ui/IntroPage.qml:101
4585+msgid "Start Messaging"
4586+msgstr "Comenceu a utilitzar la missatgeria"
4587+
4588+#: ../ui/ProfilePage.qml:63
4589+msgid "Contact Info"
4590+msgstr ""
4591+
4592+#: ../ui/ProfilePage.qml:101 ../ui/ProfilePage.qml:123
4593+#: ../ui/ProfilePage.qml:135
4594+msgid "Unknown"
4595+msgstr ""
4596+
4597+#: ../ui/ProfilePage.qml:107
4598+msgid "last seen - unknown"
4599+msgstr ""
4600+
4601+#: ../ui/ProfilePage.qml:114
4602+msgid "Phone Number"
4603+msgstr ""
4604+
4605+#: ../ui/SettingsPage.qml:16
4606+msgid "Your Phone Number"
4607+msgstr "El vostre telèfon"
4608+
4609+#: ../ui/SettingsPage.qml:29
4610+msgid "Configure push"
4611+msgstr "Configura les notificacions"
4612+
4613+#: ../ui/SettingsPage.qml:41
4614+msgid "Terminate All Other Sessions"
4615+msgstr "Finalitza totes les altres sessions"
4616+
4617+#: ../ui/SettingsPage.qml:51
4618+msgid "Are you sure you want to terminate all other sessions?"
4619+msgstr "Segur que voleu finalitzar totes les altres sessions?"
4620+
4621+#: ../ui/SettingsPage.qml:70
4622+msgid "Support"
4623+msgstr "Assistència"
4624+
4625+#: ../ui/SettingsPage.qml:74
4626+msgid "Telegram FAQ"
4627+msgstr "PMF del Telegram"
4628+
4629+#: ../ui/SettingsPage.qml:80
4630+msgid "Ask a Question"
4631+msgstr "Envieu una pregunta"
4632+
4633+#: ../ui/SettingsPage.qml:92
4634+msgid "Log Out"
4635+msgstr "Surt"
4636+
4637+#: ../ui/SettingsPage.qml:101
4638+msgid "Are you sure you want to log out?"
4639+msgstr "Segur que voleu sortir?"
4640+
4641+#. TRANSLATORS: the argument refers to the version of the app
4642+#: ../ui/SettingsPage.qml:131
4643+#, qt-format
4644+msgid "Telegram for Ubuntu %1"
4645+msgstr "Telegram per a l'Ubuntu %1"
4646+
4647+#: ../ui/SignInPage.qml:12
4648+msgid "Your phone"
4649+msgstr ""
4650+
4651+#: ../ui/SignInPage.qml:130
4652+msgid ""
4653+"Please confirm your country code\n"
4654+"and enter your phone number."
4655+msgstr ""
4656+"Confirmeu el codi de país\n"
4657+"i introduïu el vostre número de telèfon."
4658+
4659+#: ../ui/SignInPage.qml:150 ../ui/VerificationCodePage.qml:129
4660+msgid "Please wait a moment and try again"
4661+msgstr "Espereu un moment i torneu-ho a provar"
4662+
4663+#: ../ui/SignInPage.qml:152
4664+msgid "Incorrect phone number."
4665+msgstr "Número de telèfon incorrecte."
4666+
4667+#: ../ui/SignUpPage.qml:10 ../ui/SignUpPage.qml:81
4668+msgid "Sign up"
4669+msgstr "Registra'm"
4670+
4671+#: ../ui/SignUpPage.qml:26
4672+msgid "Your first and last name:"
4673+msgstr "Nom i cognoms:"
4674+
4675+#: ../ui/SignUpPage.qml:102
4676+msgid "First name is required"
4677+msgstr "Cal que introduïu el nom"
4678+
4679+#: ../ui/VerificationCodePage.qml:12
4680+msgid "Your code"
4681+msgstr ""
4682+
4683+#: ../ui/VerificationCodePage.qml:32
4684+msgid ""
4685+"We've sent an SMS with an activation code.\n"
4686+"Please enter it below.\n"
4687+msgstr ""
4688+"Us hem enviat un missatge de text amb un codi d'activació.\n"
4689+"Introduïu-lo aquí sota.\n"
4690+
4691+#. TRANSLATORS: the argument refers to a countdown time
4692+#: ../ui/VerificationCodePage.qml:43 ../ui/VerificationCodePage.qml:103
4693+#, qt-format
4694+msgid "We will call you in %1"
4695+msgstr "Us trucarem en %1"
4696+
4697+#: ../ui/VerificationCodePage.qml:68
4698+msgid "Code"
4699+msgstr "Codi"
4700+
4701+#: ../ui/VerificationCodePage.qml:89
4702+msgid "Enter"
4703+msgstr "Retorn"
4704+
4705+#: ../ui/VerificationCodePage.qml:139
4706+msgid "Incorrect code. Please try again."
4707+msgstr "El codi és incorrecte. Torneu-ho a provar."
4708+
4709+#: ../ui/VerificationCodePage.qml:165
4710+msgid "Calling you..."
4711+msgstr "Us estem trucant..."
4712
4713=== added file 'po/com.ubuntu.telegram.pot'
4714--- po/com.ubuntu.telegram.pot 1970-01-01 00:00:00 +0000
4715+++ po/com.ubuntu.telegram.pot 2014-10-11 18:44:23 +0000
4716@@ -0,0 +1,400 @@
4717+# SOME DESCRIPTIVE TITLE.
4718+# Copyright (C) YEAR Canonical Ltd.
4719+# This file is distributed under the same license as the PACKAGE package.
4720+# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
4721+#
4722+#, fuzzy
4723+msgid ""
4724+msgstr ""
4725+"Project-Id-Version: \n"
4726+"Report-Msgid-Bugs-To: \n"
4727+"POT-Creation-Date: 2014-10-11 18:52+0100\n"
4728+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
4729+"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
4730+"Language-Team: LANGUAGE <LL@li.org>\n"
4731+"Language: \n"
4732+"MIME-Version: 1.0\n"
4733+"Content-Type: text/plain; charset=CHARSET\n"
4734+"Content-Transfer-Encoding: 8bit\n"
4735+
4736+#: ../components/TelegramContactsListItem.qml:61
4737+msgid "Contact"
4738+msgstr ""
4739+
4740+#: ../components/TelegramContactsListItem.qml:77
4741+msgid "Last seen"
4742+msgstr ""
4743+
4744+#: ../components/TelegramContactsListItem.qml:86 ../ui/AddContactPage.qml:231
4745+#: ../ui/ProfilePage.qml:39
4746+msgid "online"
4747+msgstr ""
4748+
4749+#. TRANSLATORS: the argument refers to a time
4750+#: ../components/TelegramContactsListItem.qml:89 ../ui/AddContactPage.qml:234
4751+#: ../ui/ProfilePage.qml:42
4752+#, qt-format
4753+msgid "last seen %1"
4754+msgstr ""
4755+
4756+#: ../components/TelegramHeader.qml:60
4757+msgid "Connecting..."
4758+msgstr ""
4759+
4760+#: ../components/TelegramHeader.qml:60 ../ui/ContactsPage.qml:276
4761+#: ../ui/SettingsPage.qml:54 ../ui/SettingsPage.qml:104
4762+#: telegram.desktop.in.in.h:1
4763+msgid "Telegram"
4764+msgstr ""
4765+
4766+#: ../components/TgButton.qml:9
4767+msgid "Next"
4768+msgstr ""
4769+
4770+#: ../library/uitest/ui/DialogDesignPage.qml:146
4771+msgid "Enter local path to send"
4772+msgstr ""
4773+
4774+#: ../library/uitest/ui/DialogDesignPage.qml:153
4775+msgid "Enter msg to send"
4776+msgstr ""
4777+
4778+#: ../library/uitest/ui/DialogsPage.qml:127 ../ui/DialogsPage.qml:90
4779+msgid "typing..."
4780+msgstr ""
4781+
4782+#: ../library/uitest/ui/SignInPageDesign.qml:44
4783+msgid ""
4784+"Please enter your full phone \n"
4785+"number with country code"
4786+msgstr ""
4787+
4788+#: ../library/uitest/ui/SignInPageDesign.qml:66
4789+msgid "with '+' sign"
4790+msgstr ""
4791+
4792+#: ../library/uitest/ui/SignUpPageDesign.qml:44
4793+msgid ""
4794+"You are not registered yet.\n"
4795+"Please provide registration data"
4796+msgstr ""
4797+
4798+#: ../library/uitest/ui/SignUpPageDesign.qml:66
4799+msgid "first name"
4800+msgstr ""
4801+
4802+#: ../library/uitest/ui/SignUpPageDesign.qml:78
4803+msgid "last name"
4804+msgstr ""
4805+
4806+#: ../library/uitest/ui/VerificationCodePageDesign.qml:43
4807+msgid ""
4808+"We have sent you a code via SMS.\n"
4809+"Please enter it below\n"
4810+msgstr ""
4811+
4812+#: ../library/uitest/ui/VerificationCodePageDesign.qml:73
4813+msgid "Enter your code"
4814+msgstr ""
4815+
4816+#: ../library/uitest/uitest.qml:112 ../library/uitest/uitest.qml:120
4817+msgid "The code you have entered is not valid. Try again"
4818+msgstr ""
4819+
4820+#: ../library/uitest/uitest.qml:140
4821+msgid "calling user's mobile"
4822+msgstr ""
4823+
4824+#: ../telegram.qml:397
4825+msgid "Push notifications"
4826+msgstr ""
4827+
4828+#: ../telegram.qml:398
4829+msgid "To enable push, sign in to your Ubuntu One account."
4830+msgstr ""
4831+
4832+#: ../telegram.qml:400
4833+msgid "Sign in to Ubuntu One"
4834+msgstr ""
4835+
4836+#: ../telegram.qml:408
4837+msgid "Remind me later"
4838+msgstr ""
4839+
4840+#: ../telegram.qml:412
4841+msgid "Don't use push"
4842+msgstr ""
4843+
4844+#: ../ui/AddContactPage.qml:27 ../ui/ContactsPage.qml:246
4845+msgid "Add Contact"
4846+msgstr ""
4847+
4848+#: ../ui/AddContactPage.qml:32 ../ui/SignInPage.qml:118
4849+msgid "Done"
4850+msgstr ""
4851+
4852+#: ../ui/AddContactPage.qml:37 ../ui/ContactsPage.qml:264
4853+#: ../ui/ContactsPage.qml:302 ../ui/SettingsPage.qml:66
4854+#: ../ui/SettingsPage.qml:118
4855+msgid "Cancel"
4856+msgstr ""
4857+
4858+#: ../ui/AddContactPage.qml:85
4859+msgid "+1 1234 56789"
4860+msgstr ""
4861+
4862+#: ../ui/AddContactPage.qml:103
4863+msgid "last seen yesterday at 19:16"
4864+msgstr ""
4865+
4866+#: ../ui/AddContactPage.qml:123
4867+msgid "Phone number (required)"
4868+msgstr ""
4869+
4870+#: ../ui/AddContactPage.qml:140 ../ui/SignUpPage.qml:50
4871+msgid "First name (required)"
4872+msgstr ""
4873+
4874+#: ../ui/AddContactPage.qml:156 ../ui/SignUpPage.qml:63
4875+msgid "Last name (optional)"
4876+msgstr ""
4877+
4878+#: ../ui/AddContactPage.qml:204
4879+msgid "Could not add contact"
4880+msgstr ""
4881+
4882+#: ../ui/ContactsPage.qml:26 ../ui/ContactsPage.qml:33
4883+#: ../ui/DialogsPage.qml:19
4884+msgid "Search"
4885+msgstr ""
4886+
4887+#: ../ui/ContactsPage.qml:38
4888+msgid "Add"
4889+msgstr ""
4890+
4891+#: ../ui/ContactsPage.qml:46
4892+msgid "Ok"
4893+msgstr ""
4894+
4895+#: ../ui/ContactsPage.qml:55
4896+msgid "New group chat"
4897+msgstr ""
4898+
4899+#: ../ui/ContactsPage.qml:57
4900+msgid "Add to group"
4901+msgstr ""
4902+
4903+#: ../ui/ContactsPage.qml:59 ../ui/DialogsPage.qml:37
4904+msgid "Contacts"
4905+msgstr ""
4906+
4907+#: ../ui/ContactsPage.qml:81
4908+msgid "No contacts"
4909+msgstr ""
4910+
4911+#: ../ui/ContactsPage.qml:115
4912+msgid "Chat title"
4913+msgstr ""
4914+
4915+#. TRANSLATORS: the first argument refers to the number of members
4916+#. on a group conversation. The second one refers to the maximum
4917+#. number of members that are supporte for groups (currently 200).
4918+#: ../ui/ContactsPage.qml:201
4919+#, qt-format
4920+msgid "%1/%2 members"
4921+msgstr ""
4922+
4923+#: ../ui/ContactsPage.qml:248
4924+msgid "From Address Book"
4925+msgstr ""
4926+
4927+#: ../ui/ContactsPage.qml:256
4928+msgid "Enter Details"
4929+msgstr ""
4930+
4931+#: ../ui/ContactsPage.qml:277
4932+msgid "Text"
4933+msgstr ""
4934+
4935+#: ../ui/ContactsPage.qml:292 ../ui/SettingsPage.qml:57
4936+#: ../ui/SettingsPage.qml:107
4937+msgid "OK"
4938+msgstr ""
4939+
4940+#: ../ui/ContactsPage.qml:308
4941+#, qt-format
4942+msgid ""
4943+"Add %1 to %2?\n"
4944+"\n"
4945+"Number of last messages to forward:"
4946+msgstr ""
4947+
4948+#: ../ui/DialogPage.qml:23
4949+msgid "Send picture"
4950+msgstr ""
4951+
4952+#: ../ui/DialogPage.qml:30
4953+msgid "Profile Info"
4954+msgstr ""
4955+
4956+#: ../ui/DialogPage.qml:37
4957+msgid "Add member"
4958+msgstr ""
4959+
4960+#: ../ui/DialogPage.qml:83
4961+msgid "Add to contacts"
4962+msgstr ""
4963+
4964+#: ../ui/DialogPage.qml:118
4965+msgid "Type message"
4966+msgstr ""
4967+
4968+#: ../ui/DialogPage.qml:224 ../ui/ProfilePage.qml:32
4969+msgid "DELETED"
4970+msgstr ""
4971+
4972+#: ../ui/DialogsPage.qml:25
4973+msgid "Compose"
4974+msgstr ""
4975+
4976+#: ../ui/DialogsPage.qml:31
4977+msgid "New Group"
4978+msgstr ""
4979+
4980+#: ../ui/DialogsPage.qml:42 ../ui/SettingsPage.qml:10
4981+#: ../ui/SettingsPage.qml:25
4982+msgid "Settings"
4983+msgstr ""
4984+
4985+#: ../ui/DialogsPage.qml:57
4986+msgid "No chats"
4987+msgstr ""
4988+
4989+#: ../ui/IntroPage.qml:103
4990+msgid "Start Messaging"
4991+msgstr ""
4992+
4993+#: ../ui/ProfilePage.qml:81
4994+msgid "Contact Info"
4995+msgstr ""
4996+
4997+#: ../ui/ProfilePage.qml:119 ../ui/ProfilePage.qml:141
4998+#: ../ui/ProfilePage.qml:153
4999+msgid "Unknown"
5000+msgstr ""
The diff has been truncated for viewing.

Subscribers

People subscribed via source and target branches