New in v3.3.1.0:

- Groups can now have multiple administrators with the ability to edit the name and logo, and add and remove members.
- Groups that have reached their capacity of 200 users can be upgraded to supergroups of up to 1,000 members.
- Channels got a new Quick Share button right next to messages.
This commit is contained in:
rafalense 2015-11-27 22:10:12 +01:00
parent b0436c0971
commit c7be127b5c
85 changed files with 29363 additions and 4613 deletions

View File

@ -7,23 +7,16 @@ repositories {
dependencies { dependencies {
compile 'com.android.support:support-v4:23.1.+' compile 'com.android.support:support-v4:23.1.+'
compile 'com.google.android.gms:play-services:3.2.+' compile 'com.google.android.gms:play-services:3.2.+'
//compile 'com.google.android.gms:play-services:7.5.0' compile 'net.hockeyapp.android:HockeySDK:3.6.+'
compile 'net.hockeyapp.android:HockeySDK:3.5.+'
compile 'com.googlecode.mp4parser:isoparser:1.0.+' compile 'com.googlecode.mp4parser:isoparser:1.0.+'
compile 'org.apache.httpcomponents:httpmime:4.2.1'
} }
android { android {
compileSdkVersion 23 compileSdkVersion 23
buildToolsVersion '23.0.1' buildToolsVersion '23.0.2'
useLibrary 'org.apache.http.legacy' useLibrary 'org.apache.http.legacy'
packagingOptions {
exclude 'META-INF/NOTICE.txt'
exclude 'META-INF/LICENSE.txt'
}
compileOptions { compileOptions {
sourceCompatibility JavaVersion.VERSION_1_7 sourceCompatibility JavaVersion.VERSION_1_7
targetCompatibility JavaVersion.VERSION_1_7 targetCompatibility JavaVersion.VERSION_1_7
@ -89,7 +82,7 @@ android {
applicationId "org.telegram.plus" applicationId "org.telegram.plus"
minSdkVersion 8 minSdkVersion 8
targetSdkVersion 23 targetSdkVersion 23
versionCode 661 versionCode 686
versionName "3.2.6.2" versionName "3.3.1.0"
} }
} }

View File

@ -187,7 +187,7 @@ include $(CLEAR_VARS)
LOCAL_PRELINK_MODULE := false LOCAL_PRELINK_MODULE := false
LOCAL_STATIC_LIBRARIES := webp sqlite tgnet breakpad LOCAL_STATIC_LIBRARIES := webp sqlite tgnet breakpad
LOCAL_MODULE := tmessages.14 LOCAL_MODULE := tmessages.15
LOCAL_CFLAGS := -w -std=c11 -Os -DNULL=0 -DSOCKLEN_T=socklen_t -DLOCALE_NOT_USED -D_LARGEFILE_SOURCE=1 -D_FILE_OFFSET_BITS=64 LOCAL_CFLAGS := -w -std=c11 -Os -DNULL=0 -DSOCKLEN_T=socklen_t -DLOCALE_NOT_USED -D_LARGEFILE_SOURCE=1 -D_FILE_OFFSET_BITS=64
LOCAL_CFLAGS += -Drestrict='' -D__EMX__ -DOPUS_BUILD -DFIXED_POINT -DUSE_ALLOCA -DHAVE_LRINT -DHAVE_LRINTF -fno-math-errno LOCAL_CFLAGS += -Drestrict='' -D__EMX__ -DOPUS_BUILD -DFIXED_POINT -DUSE_ALLOCA -DHAVE_LRINT -DHAVE_LRINTF -fno-math-errno
LOCAL_CFLAGS += -DANDROID_NDK -DDISABLE_IMPORTGL -fno-strict-aliasing -fprefetch-loop-arrays -DAVOID_TABLES -DANDROID_TILE_BASED_DECODE -DANDROID_ARMV6_IDCT -ffast-math LOCAL_CFLAGS += -DANDROID_NDK -DDISABLE_IMPORTGL -fno-strict-aliasing -fprefetch-loop-arrays -DAVOID_TABLES -DANDROID_TILE_BASED_DECODE -DANDROID_ARMV6_IDCT -ffast-math

File diff suppressed because it is too large Load Diff

View File

@ -31,7 +31,7 @@
** part of the build process. ** part of the build process.
*/ */
#ifndef _SQLITE3_H_ #ifndef _SQLITE3_H_
#define _SQLITE3_H_ #define _SQLITE3_H_
#include <stdarg.h> /* Needed for the definition of va_list */ #include <stdarg.h> /* Needed for the definition of va_list */
/* /*
@ -111,9 +111,9 @@ extern "C" {
** [sqlite3_libversion_number()], [sqlite3_sourceid()], ** [sqlite3_libversion_number()], [sqlite3_sourceid()],
** [sqlite_version()] and [sqlite_source_id()]. ** [sqlite_version()] and [sqlite_source_id()].
*/ */
#define SQLITE_VERSION "3.8.11.1" #define SQLITE_VERSION "3.9.2"
#define SQLITE_VERSION_NUMBER 3008011 #define SQLITE_VERSION_NUMBER 3009002
#define SQLITE_SOURCE_ID "2015-07-29 20:00:57 cf538e2783e468bbc25e7cb2a9ee64d3e0e80b2f" #define SQLITE_SOURCE_ID "2015-11-02 18:31:45 bda77dda9697c463c3d0704014d51627fceee328"
/* /*
** CAPI3REF: Run-Time Library Version Numbers ** CAPI3REF: Run-Time Library Version Numbers
@ -124,7 +124,7 @@ extern "C" {
** but are associated with the library instead of the header file. ^(Cautious ** but are associated with the library instead of the header file. ^(Cautious
** programmers might include assert() statements in their application to ** programmers might include assert() statements in their application to
** verify that values returned by these interfaces match the macros in ** verify that values returned by these interfaces match the macros in
** the header, and thus insure that the application is ** the header, and thus ensure that the application is
** compiled with matching library and header files. ** compiled with matching library and header files.
** **
** <blockquote><pre> ** <blockquote><pre>
@ -374,7 +374,7 @@ typedef int (*sqlite3_callback)(void*,int,char**, char**);
** Restrictions: ** Restrictions:
** **
** <ul> ** <ul>
** <li> The application must insure that the 1st parameter to sqlite3_exec() ** <li> The application must ensure that the 1st parameter to sqlite3_exec()
** is a valid and open [database connection]. ** is a valid and open [database connection].
** <li> The application must not close the [database connection] specified by ** <li> The application must not close the [database connection] specified by
** the 1st parameter to sqlite3_exec() while sqlite3_exec() is running. ** the 1st parameter to sqlite3_exec() while sqlite3_exec() is running.
@ -477,6 +477,7 @@ SQLITE_API int SQLITE_STDCALL sqlite3_exec(
#define SQLITE_IOERR_MMAP (SQLITE_IOERR | (24<<8)) #define SQLITE_IOERR_MMAP (SQLITE_IOERR | (24<<8))
#define SQLITE_IOERR_GETTEMPPATH (SQLITE_IOERR | (25<<8)) #define SQLITE_IOERR_GETTEMPPATH (SQLITE_IOERR | (25<<8))
#define SQLITE_IOERR_CONVPATH (SQLITE_IOERR | (26<<8)) #define SQLITE_IOERR_CONVPATH (SQLITE_IOERR | (26<<8))
#define SQLITE_IOERR_VNODE (SQLITE_IOERR | (27<<8))
#define SQLITE_LOCKED_SHAREDCACHE (SQLITE_LOCKED | (1<<8)) #define SQLITE_LOCKED_SHAREDCACHE (SQLITE_LOCKED | (1<<8))
#define SQLITE_BUSY_RECOVERY (SQLITE_BUSY | (1<<8)) #define SQLITE_BUSY_RECOVERY (SQLITE_BUSY | (1<<8))
#define SQLITE_BUSY_SNAPSHOT (SQLITE_BUSY | (2<<8)) #define SQLITE_BUSY_SNAPSHOT (SQLITE_BUSY | (2<<8))
@ -1366,9 +1367,11 @@ SQLITE_API int SQLITE_STDCALL sqlite3_os_end(void);
** applications and so this routine is usually not necessary. It is ** applications and so this routine is usually not necessary. It is
** provided to support rare applications with unusual needs. ** provided to support rare applications with unusual needs.
** **
** The sqlite3_config() interface is not threadsafe. The application ** <b>The sqlite3_config() interface is not threadsafe. The application
** must insure that no other SQLite interfaces are invoked by other ** must ensure that no other SQLite interfaces are invoked by other
** threads while sqlite3_config() is running. Furthermore, sqlite3_config() ** threads while sqlite3_config() is running.</b>
**
** The sqlite3_config() interface
** may only be invoked prior to library initialization using ** may only be invoked prior to library initialization using
** [sqlite3_initialize()] or after shutdown by [sqlite3_shutdown()]. ** [sqlite3_initialize()] or after shutdown by [sqlite3_shutdown()].
** ^If sqlite3_config() is called after [sqlite3_initialize()] and before ** ^If sqlite3_config() is called after [sqlite3_initialize()] and before
@ -3373,7 +3376,8 @@ SQLITE_API int SQLITE_STDCALL sqlite3_stmt_readonly(sqlite3_stmt *pStmt);
** **
** ^The sqlite3_stmt_busy(S) interface returns true (non-zero) if the ** ^The sqlite3_stmt_busy(S) interface returns true (non-zero) if the
** [prepared statement] S has been stepped at least once using ** [prepared statement] S has been stepped at least once using
** [sqlite3_step(S)] but has not run to completion and/or has not ** [sqlite3_step(S)] but has neither run to completion (returned
** [SQLITE_DONE] from [sqlite3_step(S)]) nor
** been reset using [sqlite3_reset(S)]. ^The sqlite3_stmt_busy(S) ** been reset using [sqlite3_reset(S)]. ^The sqlite3_stmt_busy(S)
** interface returns false if S is a NULL pointer. If S is not a ** interface returns false if S is a NULL pointer. If S is not a
** NULL pointer and is not a pointer to a valid [prepared statement] ** NULL pointer and is not a pointer to a valid [prepared statement]
@ -3626,7 +3630,7 @@ SQLITE_API const char *SQLITE_STDCALL sqlite3_bind_parameter_name(sqlite3_stmt*,
** **
** See also: [sqlite3_bind_blob|sqlite3_bind()], ** See also: [sqlite3_bind_blob|sqlite3_bind()],
** [sqlite3_bind_parameter_count()], and ** [sqlite3_bind_parameter_count()], and
** [sqlite3_bind_parameter_index()]. ** [sqlite3_bind_parameter_name()].
*/ */
SQLITE_API int SQLITE_STDCALL sqlite3_bind_parameter_index(sqlite3_stmt*, const char *zName); SQLITE_API int SQLITE_STDCALL sqlite3_bind_parameter_index(sqlite3_stmt*, const char *zName);
@ -4355,6 +4359,22 @@ SQLITE_API const void *SQLITE_STDCALL sqlite3_value_text16be(sqlite3_value*);
SQLITE_API int SQLITE_STDCALL sqlite3_value_type(sqlite3_value*); SQLITE_API int SQLITE_STDCALL sqlite3_value_type(sqlite3_value*);
SQLITE_API int SQLITE_STDCALL sqlite3_value_numeric_type(sqlite3_value*); SQLITE_API int SQLITE_STDCALL sqlite3_value_numeric_type(sqlite3_value*);
/*
** CAPI3REF: Finding The Subtype Of SQL Values
** METHOD: sqlite3_value
**
** The sqlite3_value_subtype(V) function returns the subtype for
** an [application-defined SQL function] argument V. The subtype
** information can be used to pass a limited amount of context from
** one SQL function to another. Use the [sqlite3_result_subtype()]
** routine to set the subtype for the return value of an SQL function.
**
** SQLite makes no use of subtype itself. It merely passes the subtype
** from the result of one [application-defined SQL function] into the
** input of another.
*/
SQLITE_API unsigned int SQLITE_STDCALL sqlite3_value_subtype(sqlite3_value*);
/* /*
** CAPI3REF: Copy And Free SQL Values ** CAPI3REF: Copy And Free SQL Values
** METHOD: sqlite3_value ** METHOD: sqlite3_value
@ -4654,6 +4674,21 @@ SQLITE_API void SQLITE_STDCALL sqlite3_result_value(sqlite3_context*, sqlite3_va
SQLITE_API void SQLITE_STDCALL sqlite3_result_zeroblob(sqlite3_context*, int n); SQLITE_API void SQLITE_STDCALL sqlite3_result_zeroblob(sqlite3_context*, int n);
SQLITE_API int SQLITE_STDCALL sqlite3_result_zeroblob64(sqlite3_context*, sqlite3_uint64 n); SQLITE_API int SQLITE_STDCALL sqlite3_result_zeroblob64(sqlite3_context*, sqlite3_uint64 n);
/*
** CAPI3REF: Setting The Subtype Of An SQL Function
** METHOD: sqlite3_context
**
** The sqlite3_result_subtype(C,T) function causes the subtype of
** the result from the [application-defined SQL function] with
** [sqlite3_context] C to be the value T. Only the lower 8 bits
** of the subtype T are preserved in current versions of SQLite;
** higher order bits are discarded.
** The number of subtype bytes preserved by SQLite might increase
** in future releases of SQLite.
*/
SQLITE_API void SQLITE_STDCALL sqlite3_result_subtype(sqlite3_context*,unsigned int);
/* /*
** CAPI3REF: Define New Collating Sequences ** CAPI3REF: Define New Collating Sequences
** METHOD: sqlite3 ** METHOD: sqlite3
@ -5599,13 +5634,31 @@ struct sqlite3_module {
** ^The estimatedRows value is an estimate of the number of rows that ** ^The estimatedRows value is an estimate of the number of rows that
** will be returned by the strategy. ** will be returned by the strategy.
** **
** The xBestIndex method may optionally populate the idxFlags field with a
** mask of SQLITE_INDEX_SCAN_* flags. Currently there is only one such flag -
** SQLITE_INDEX_SCAN_UNIQUE. If the xBestIndex method sets this flag, SQLite
** assumes that the strategy may visit at most one row.
**
** Additionally, if xBestIndex sets the SQLITE_INDEX_SCAN_UNIQUE flag, then
** SQLite also assumes that if a call to the xUpdate() method is made as
** part of the same statement to delete or update a virtual table row and the
** implementation returns SQLITE_CONSTRAINT, then there is no need to rollback
** any database changes. In other words, if the xUpdate() returns
** SQLITE_CONSTRAINT, the database contents must be exactly as they were
** before xUpdate was called. By contrast, if SQLITE_INDEX_SCAN_UNIQUE is not
** set and xUpdate returns SQLITE_CONSTRAINT, any database changes made by
** the xUpdate method are automatically rolled back by SQLite.
**
** IMPORTANT: The estimatedRows field was added to the sqlite3_index_info ** IMPORTANT: The estimatedRows field was added to the sqlite3_index_info
** structure for SQLite version 3.8.2. If a virtual table extension is ** structure for SQLite version 3.8.2. If a virtual table extension is
** used with an SQLite version earlier than 3.8.2, the results of attempting ** used with an SQLite version earlier than 3.8.2, the results of attempting
** to read or write the estimatedRows field are undefined (but are likely ** to read or write the estimatedRows field are undefined (but are likely
** to included crashing the application). The estimatedRows field should ** to included crashing the application). The estimatedRows field should
** therefore only be used if [sqlite3_libversion_number()] returns a ** therefore only be used if [sqlite3_libversion_number()] returns a
** value greater than or equal to 3008002. ** value greater than or equal to 3008002. Similarly, the idxFlags field
** was added for version 3.9.0. It may therefore only be used if
** sqlite3_libversion_number() returns a value greater than or equal to
** 3009000.
*/ */
struct sqlite3_index_info { struct sqlite3_index_info {
/* Inputs */ /* Inputs */
@ -5633,8 +5686,15 @@ struct sqlite3_index_info {
double estimatedCost; /* Estimated cost of using this index */ double estimatedCost; /* Estimated cost of using this index */
/* Fields below are only available in SQLite 3.8.2 and later */ /* Fields below are only available in SQLite 3.8.2 and later */
sqlite3_int64 estimatedRows; /* Estimated number of rows returned */ sqlite3_int64 estimatedRows; /* Estimated number of rows returned */
/* Fields below are only available in SQLite 3.9.0 and later */
int idxFlags; /* Mask of SQLITE_INDEX_SCAN_* flags */
}; };
/*
** CAPI3REF: Virtual Table Scan Flags
*/
#define SQLITE_INDEX_SCAN_UNIQUE 1 /* Scan visits at most 1 row */
/* /*
** CAPI3REF: Virtual Table Constraint Operator Codes ** CAPI3REF: Virtual Table Constraint Operator Codes
** **
@ -6092,6 +6152,9 @@ SQLITE_API int SQLITE_STDCALL sqlite3_vfs_unregister(sqlite3_vfs*);
** <li> SQLITE_MUTEX_STATIC_APP1 ** <li> SQLITE_MUTEX_STATIC_APP1
** <li> SQLITE_MUTEX_STATIC_APP2 ** <li> SQLITE_MUTEX_STATIC_APP2
** <li> SQLITE_MUTEX_STATIC_APP3 ** <li> SQLITE_MUTEX_STATIC_APP3
** <li> SQLITE_MUTEX_STATIC_VFS1
** <li> SQLITE_MUTEX_STATIC_VFS2
** <li> SQLITE_MUTEX_STATIC_VFS3
** </ul> ** </ul>
** **
** ^The first two constants (SQLITE_MUTEX_FAST and SQLITE_MUTEX_RECURSIVE) ** ^The first two constants (SQLITE_MUTEX_FAST and SQLITE_MUTEX_RECURSIVE)
@ -7858,3 +7921,523 @@ struct sqlite3_rtree_query_info {
#endif /* ifndef _SQLITE3RTREE_H_ */ #endif /* ifndef _SQLITE3RTREE_H_ */
/*
** 2014 May 31
**
** The author disclaims copyright to this source code. In place of
** a legal notice, here is a blessing:
**
** May you do good and not evil.
** May you find forgiveness for yourself and forgive others.
** May you share freely, never taking more than you give.
**
******************************************************************************
**
** Interfaces to extend FTS5. Using the interfaces defined in this file,
** FTS5 may be extended with:
**
** * custom tokenizers, and
** * custom auxiliary functions.
*/
#ifndef _FTS5_H
#define _FTS5_H
#ifdef __cplusplus
extern "C" {
#endif
/*************************************************************************
** CUSTOM AUXILIARY FUNCTIONS
**
** Virtual table implementations may overload SQL functions by implementing
** the sqlite3_module.xFindFunction() method.
*/
typedef struct Fts5ExtensionApi Fts5ExtensionApi;
typedef struct Fts5Context Fts5Context;
typedef struct Fts5PhraseIter Fts5PhraseIter;
typedef void (*fts5_extension_function)(
const Fts5ExtensionApi *pApi, /* API offered by current FTS version */
Fts5Context *pFts, /* First arg to pass to pApi functions */
sqlite3_context *pCtx, /* Context for returning result/error */
int nVal, /* Number of values in apVal[] array */
sqlite3_value **apVal /* Array of trailing arguments */
);
struct Fts5PhraseIter {
const unsigned char *a;
const unsigned char *b;
};
/*
** EXTENSION API FUNCTIONS
**
** xUserData(pFts):
** Return a copy of the context pointer the extension function was
** registered with.
**
** xColumnTotalSize(pFts, iCol, pnToken):
** If parameter iCol is less than zero, set output variable *pnToken
** to the total number of tokens in the FTS5 table. Or, if iCol is
** non-negative but less than the number of columns in the table, return
** the total number of tokens in column iCol, considering all rows in
** the FTS5 table.
**
** If parameter iCol is greater than or equal to the number of columns
** in the table, SQLITE_RANGE is returned. Or, if an error occurs (e.g.
** an OOM condition or IO error), an appropriate SQLite error code is
** returned.
**
** xColumnCount(pFts):
** Return the number of columns in the table.
**
** xColumnSize(pFts, iCol, pnToken):
** If parameter iCol is less than zero, set output variable *pnToken
** to the total number of tokens in the current row. Or, if iCol is
** non-negative but less than the number of columns in the table, set
** *pnToken to the number of tokens in column iCol of the current row.
**
** If parameter iCol is greater than or equal to the number of columns
** in the table, SQLITE_RANGE is returned. Or, if an error occurs (e.g.
** an OOM condition or IO error), an appropriate SQLite error code is
** returned.
**
** xColumnText:
** This function attempts to retrieve the text of column iCol of the
** current document. If successful, (*pz) is set to point to a buffer
** containing the text in utf-8 encoding, (*pn) is set to the size in bytes
** (not characters) of the buffer and SQLITE_OK is returned. Otherwise,
** if an error occurs, an SQLite error code is returned and the final values
** of (*pz) and (*pn) are undefined.
**
** xPhraseCount:
** Returns the number of phrases in the current query expression.
**
** xPhraseSize:
** Returns the number of tokens in phrase iPhrase of the query. Phrases
** are numbered starting from zero.
**
** xInstCount:
** Set *pnInst to the total number of occurrences of all phrases within
** the query within the current row. Return SQLITE_OK if successful, or
** an error code (i.e. SQLITE_NOMEM) if an error occurs.
**
** xInst:
** Query for the details of phrase match iIdx within the current row.
** Phrase matches are numbered starting from zero, so the iIdx argument
** should be greater than or equal to zero and smaller than the value
** output by xInstCount().
**
** Returns SQLITE_OK if successful, or an error code (i.e. SQLITE_NOMEM)
** if an error occurs.
**
** xRowid:
** Returns the rowid of the current row.
**
** xTokenize:
** Tokenize text using the tokenizer belonging to the FTS5 table.
**
** xQueryPhrase(pFts5, iPhrase, pUserData, xCallback):
** This API function is used to query the FTS table for phrase iPhrase
** of the current query. Specifically, a query equivalent to:
**
** ... FROM ftstable WHERE ftstable MATCH $p ORDER BY rowid
**
** with $p set to a phrase equivalent to the phrase iPhrase of the
** current query is executed. For each row visited, the callback function
** passed as the fourth argument is invoked. The context and API objects
** passed to the callback function may be used to access the properties of
** each matched row. Invoking Api.xUserData() returns a copy of the pointer
** passed as the third argument to pUserData.
**
** If the callback function returns any value other than SQLITE_OK, the
** query is abandoned and the xQueryPhrase function returns immediately.
** If the returned value is SQLITE_DONE, xQueryPhrase returns SQLITE_OK.
** Otherwise, the error code is propagated upwards.
**
** If the query runs to completion without incident, SQLITE_OK is returned.
** Or, if some error occurs before the query completes or is aborted by
** the callback, an SQLite error code is returned.
**
**
** xSetAuxdata(pFts5, pAux, xDelete)
**
** Save the pointer passed as the second argument as the extension functions
** "auxiliary data". The pointer may then be retrieved by the current or any
** future invocation of the same fts5 extension function made as part of
** of the same MATCH query using the xGetAuxdata() API.
**
** Each extension function is allocated a single auxiliary data slot for
** each FTS query (MATCH expression). If the extension function is invoked
** more than once for a single FTS query, then all invocations share a
** single auxiliary data context.
**
** If there is already an auxiliary data pointer when this function is
** invoked, then it is replaced by the new pointer. If an xDelete callback
** was specified along with the original pointer, it is invoked at this
** point.
**
** The xDelete callback, if one is specified, is also invoked on the
** auxiliary data pointer after the FTS5 query has finished.
**
** If an error (e.g. an OOM condition) occurs within this function, an
** the auxiliary data is set to NULL and an error code returned. If the
** xDelete parameter was not NULL, it is invoked on the auxiliary data
** pointer before returning.
**
**
** xGetAuxdata(pFts5, bClear)
**
** Returns the current auxiliary data pointer for the fts5 extension
** function. See the xSetAuxdata() method for details.
**
** If the bClear argument is non-zero, then the auxiliary data is cleared
** (set to NULL) before this function returns. In this case the xDelete,
** if any, is not invoked.
**
**
** xRowCount(pFts5, pnRow)
**
** This function is used to retrieve the total number of rows in the table.
** In other words, the same value that would be returned by:
**
** SELECT count(*) FROM ftstable;
**
** xPhraseFirst()
** This function is used, along with type Fts5PhraseIter and the xPhraseNext
** method, to iterate through all instances of a single query phrase within
** the current row. This is the same information as is accessible via the
** xInstCount/xInst APIs. While the xInstCount/xInst APIs are more convenient
** to use, this API may be faster under some circumstances. To iterate
** through instances of phrase iPhrase, use the following code:
**
** Fts5PhraseIter iter;
** int iCol, iOff;
** for(pApi->xPhraseFirst(pFts, iPhrase, &iter, &iCol, &iOff);
** iOff>=0;
** pApi->xPhraseNext(pFts, &iter, &iCol, &iOff)
** ){
** // An instance of phrase iPhrase at offset iOff of column iCol
** }
**
** The Fts5PhraseIter structure is defined above. Applications should not
** modify this structure directly - it should only be used as shown above
** with the xPhraseFirst() and xPhraseNext() API methods.
**
** xPhraseNext()
** See xPhraseFirst above.
*/
struct Fts5ExtensionApi {
int iVersion; /* Currently always set to 1 */
void *(*xUserData)(Fts5Context*);
int (*xColumnCount)(Fts5Context*);
int (*xRowCount)(Fts5Context*, sqlite3_int64 *pnRow);
int (*xColumnTotalSize)(Fts5Context*, int iCol, sqlite3_int64 *pnToken);
int (*xTokenize)(Fts5Context*,
const char *pText, int nText, /* Text to tokenize */
void *pCtx, /* Context passed to xToken() */
int (*xToken)(void*, int, const char*, int, int, int) /* Callback */
);
int (*xPhraseCount)(Fts5Context*);
int (*xPhraseSize)(Fts5Context*, int iPhrase);
int (*xInstCount)(Fts5Context*, int *pnInst);
int (*xInst)(Fts5Context*, int iIdx, int *piPhrase, int *piCol, int *piOff);
sqlite3_int64 (*xRowid)(Fts5Context*);
int (*xColumnText)(Fts5Context*, int iCol, const char **pz, int *pn);
int (*xColumnSize)(Fts5Context*, int iCol, int *pnToken);
int (*xQueryPhrase)(Fts5Context*, int iPhrase, void *pUserData,
int(*)(const Fts5ExtensionApi*,Fts5Context*,void*)
);
int (*xSetAuxdata)(Fts5Context*, void *pAux, void(*xDelete)(void*));
void *(*xGetAuxdata)(Fts5Context*, int bClear);
void (*xPhraseFirst)(Fts5Context*, int iPhrase, Fts5PhraseIter*, int*, int*);
void (*xPhraseNext)(Fts5Context*, Fts5PhraseIter*, int *piCol, int *piOff);
};
/*
** CUSTOM AUXILIARY FUNCTIONS
*************************************************************************/
/*************************************************************************
** CUSTOM TOKENIZERS
**
** Applications may also register custom tokenizer types. A tokenizer
** is registered by providing fts5 with a populated instance of the
** following structure. All structure methods must be defined, setting
** any member of the fts5_tokenizer struct to NULL leads to undefined
** behaviour. The structure methods are expected to function as follows:
**
** xCreate:
** This function is used to allocate and inititalize a tokenizer instance.
** A tokenizer instance is required to actually tokenize text.
**
** The first argument passed to this function is a copy of the (void*)
** pointer provided by the application when the fts5_tokenizer object
** was registered with FTS5 (the third argument to xCreateTokenizer()).
** The second and third arguments are an array of nul-terminated strings
** containing the tokenizer arguments, if any, specified following the
** tokenizer name as part of the CREATE VIRTUAL TABLE statement used
** to create the FTS5 table.
**
** The final argument is an output variable. If successful, (*ppOut)
** should be set to point to the new tokenizer handle and SQLITE_OK
** returned. If an error occurs, some value other than SQLITE_OK should
** be returned. In this case, fts5 assumes that the final value of *ppOut
** is undefined.
**
** xDelete:
** This function is invoked to delete a tokenizer handle previously
** allocated using xCreate(). Fts5 guarantees that this function will
** be invoked exactly once for each successful call to xCreate().
**
** xTokenize:
** This function is expected to tokenize the nText byte string indicated
** by argument pText. pText may or may not be nul-terminated. The first
** argument passed to this function is a pointer to an Fts5Tokenizer object
** returned by an earlier call to xCreate().
**
** The second argument indicates the reason that FTS5 is requesting
** tokenization of the supplied text. This is always one of the following
** four values:
**
** <ul><li> <b>FTS5_TOKENIZE_DOCUMENT</b> - A document is being inserted into
** or removed from the FTS table. The tokenizer is being invoked to
** determine the set of tokens to add to (or delete from) the
** FTS index.
**
** <li> <b>FTS5_TOKENIZE_QUERY</b> - A MATCH query is being executed
** against the FTS index. The tokenizer is being called to tokenize
** a bareword or quoted string specified as part of the query.
**
** <li> <b>(FTS5_TOKENIZE_QUERY | FTS5_TOKENIZE_PREFIX)</b> - Same as
** FTS5_TOKENIZE_QUERY, except that the bareword or quoted string is
** followed by a "*" character, indicating that the last token
** returned by the tokenizer will be treated as a token prefix.
**
** <li> <b>FTS5_TOKENIZE_AUX</b> - The tokenizer is being invoked to
** satisfy an fts5_api.xTokenize() request made by an auxiliary
** function. Or an fts5_api.xColumnSize() request made by the same
** on a columnsize=0 database.
** </ul>
**
** For each token in the input string, the supplied callback xToken() must
** be invoked. The first argument to it should be a copy of the pointer
** passed as the second argument to xTokenize(). The third and fourth
** arguments are a pointer to a buffer containing the token text, and the
** size of the token in bytes. The 4th and 5th arguments are the byte offsets
** of the first byte of and first byte immediately following the text from
** which the token is derived within the input.
**
** The second argument passed to the xToken() callback ("tflags") should
** normally be set to 0. The exception is if the tokenizer supports
** synonyms. In this case see the discussion below for details.
**
** FTS5 assumes the xToken() callback is invoked for each token in the
** order that they occur within the input text.
**
** If an xToken() callback returns any value other than SQLITE_OK, then
** the tokenization should be abandoned and the xTokenize() method should
** immediately return a copy of the xToken() return value. Or, if the
** input buffer is exhausted, xTokenize() should return SQLITE_OK. Finally,
** if an error occurs with the xTokenize() implementation itself, it
** may abandon the tokenization and return any error code other than
** SQLITE_OK or SQLITE_DONE.
**
** SYNONYM SUPPORT
**
** Custom tokenizers may also support synonyms. Consider a case in which a
** user wishes to query for a phrase such as "first place". Using the
** built-in tokenizers, the FTS5 query 'first + place' will match instances
** of "first place" within the document set, but not alternative forms
** such as "1st place". In some applications, it would be better to match
** all instances of "first place" or "1st place" regardless of which form
** the user specified in the MATCH query text.
**
** There are several ways to approach this in FTS5:
**
** <ol><li> By mapping all synonyms to a single token. In this case, the
** In the above example, this means that the tokenizer returns the
** same token for inputs "first" and "1st". Say that token is in
** fact "first", so that when the user inserts the document "I won
** 1st place" entries are added to the index for tokens "i", "won",
** "first" and "place". If the user then queries for '1st + place',
** the tokenizer substitutes "first" for "1st" and the query works
** as expected.
**
** <li> By adding multiple synonyms for a single term to the FTS index.
** In this case, when tokenizing query text, the tokenizer may
** provide multiple synonyms for a single term within the document.
** FTS5 then queries the index for each synonym individually. For
** example, faced with the query:
**
** <codeblock>
** ... MATCH 'first place'</codeblock>
**
** the tokenizer offers both "1st" and "first" as synonyms for the
** first token in the MATCH query and FTS5 effectively runs a query
** similar to:
**
** <codeblock>
** ... MATCH '(first OR 1st) place'</codeblock>
**
** except that, for the purposes of auxiliary functions, the query
** still appears to contain just two phrases - "(first OR 1st)"
** being treated as a single phrase.
**
** <li> By adding multiple synonyms for a single term to the FTS index.
** Using this method, when tokenizing document text, the tokenizer
** provides multiple synonyms for each token. So that when a
** document such as "I won first place" is tokenized, entries are
** added to the FTS index for "i", "won", "first", "1st" and
** "place".
**
** This way, even if the tokenizer does not provide synonyms
** when tokenizing query text (it should not - to do would be
** inefficient), it doesn't matter if the user queries for
** 'first + place' or '1st + place', as there are entires in the
** FTS index corresponding to both forms of the first token.
** </ol>
**
** Whether it is parsing document or query text, any call to xToken that
** specifies a <i>tflags</i> argument with the FTS5_TOKEN_COLOCATED bit
** is considered to supply a synonym for the previous token. For example,
** when parsing the document "I won first place", a tokenizer that supports
** synonyms would call xToken() 5 times, as follows:
**
** <codeblock>
** xToken(pCtx, 0, "i", 1, 0, 1);
** xToken(pCtx, 0, "won", 3, 2, 5);
** xToken(pCtx, 0, "first", 5, 6, 11);
** xToken(pCtx, FTS5_TOKEN_COLOCATED, "1st", 3, 6, 11);
** xToken(pCtx, 0, "place", 5, 12, 17);
**</codeblock>
**
** It is an error to specify the FTS5_TOKEN_COLOCATED flag the first time
** xToken() is called. Multiple synonyms may be specified for a single token
** by making multiple calls to xToken(FTS5_TOKEN_COLOCATED) in sequence.
** There is no limit to the number of synonyms that may be provided for a
** single token.
**
** In many cases, method (1) above is the best approach. It does not add
** extra data to the FTS index or require FTS5 to query for multiple terms,
** so it is efficient in terms of disk space and query speed. However, it
** does not support prefix queries very well. If, as suggested above, the
** token "first" is subsituted for "1st" by the tokenizer, then the query:
**
** <codeblock>
** ... MATCH '1s*'</codeblock>
**
** will not match documents that contain the token "1st" (as the tokenizer
** will probably not map "1s" to any prefix of "first").
**
** For full prefix support, method (3) may be preferred. In this case,
** because the index contains entries for both "first" and "1st", prefix
** queries such as 'fi*' or '1s*' will match correctly. However, because
** extra entries are added to the FTS index, this method uses more space
** within the database.
**
** Method (2) offers a midpoint between (1) and (3). Using this method,
** a query such as '1s*' will match documents that contain the literal
** token "1st", but not "first" (assuming the tokenizer is not able to
** provide synonyms for prefixes). However, a non-prefix query like '1st'
** will match against "1st" and "first". This method does not require
** extra disk space, as no extra entries are added to the FTS index.
** On the other hand, it may require more CPU cycles to run MATCH queries,
** as separate queries of the FTS index are required for each synonym.
**
** When using methods (2) or (3), it is important that the tokenizer only
** provide synonyms when tokenizing document text (method (2)) or query
** text (method (3)), not both. Doing so will not cause any errors, but is
** inefficient.
*/
typedef struct Fts5Tokenizer Fts5Tokenizer;
typedef struct fts5_tokenizer fts5_tokenizer;
struct fts5_tokenizer {
int (*xCreate)(void*, const char **azArg, int nArg, Fts5Tokenizer **ppOut);
void (*xDelete)(Fts5Tokenizer*);
int (*xTokenize)(Fts5Tokenizer*,
void *pCtx,
int flags, /* Mask of FTS5_TOKENIZE_* flags */
const char *pText, int nText,
int (*xToken)(
void *pCtx, /* Copy of 2nd argument to xTokenize() */
int tflags, /* Mask of FTS5_TOKEN_* flags */
const char *pToken, /* Pointer to buffer containing token */
int nToken, /* Size of token in bytes */
int iStart, /* Byte offset of token within input text */
int iEnd /* Byte offset of end of token within input text */
)
);
};
/* Flags that may be passed as the third argument to xTokenize() */
#define FTS5_TOKENIZE_QUERY 0x0001
#define FTS5_TOKENIZE_PREFIX 0x0002
#define FTS5_TOKENIZE_DOCUMENT 0x0004
#define FTS5_TOKENIZE_AUX 0x0008
/* Flags that may be passed by the tokenizer implementation back to FTS5
** as the third argument to the supplied xToken callback. */
#define FTS5_TOKEN_COLOCATED 0x0001 /* Same position as prev. token */
/*
** END OF CUSTOM TOKENIZERS
*************************************************************************/
/*************************************************************************
** FTS5 EXTENSION REGISTRATION API
*/
typedef struct fts5_api fts5_api;
struct fts5_api {
int iVersion; /* Currently always set to 2 */
/* Create a new tokenizer */
int (*xCreateTokenizer)(
fts5_api *pApi,
const char *zName,
void *pContext,
fts5_tokenizer *pTokenizer,
void (*xDestroy)(void*)
);
/* Find an existing tokenizer */
int (*xFindTokenizer)(
fts5_api *pApi,
const char *zName,
void **ppContext,
fts5_tokenizer *pTokenizer
);
/* Create a new auxiliary function */
int (*xCreateFunction)(
fts5_api *pApi,
const char *zName,
void *pContext,
fts5_extension_function xFunction,
void (*xDestroy)(void*)
);
};
/*
** END OF REGISTRATION API
*************************************************************************/
#ifdef __cplusplus
} /* end of the 'extern "C"' block */
#endif
#endif /* _FTS5_H */

View File

@ -159,7 +159,7 @@
</service> </service>
<service <service
android:name=".TgChooserTargetService" android:name="org.telegram.messenger.TgChooserTargetService"
android:label="@string/AppName" android:label="@string/AppName"
android:permission="android.permission.BIND_CHOOSER_TARGET_SERVICE"> android:permission="android.permission.BIND_CHOOSER_TARGET_SERVICE">
<intent-filter> <intent-filter>

View File

@ -1,53 +1,53 @@
1876;JM;Jamaica 1876;JM;Jamaica;XXX XXXX
1869;KN;Saint Kitts & Nevis 1869;KN;Saint Kitts & Nevis;XXX XXXX
1868;TT;Trinidad & Tobago 1868;TT;Trinidad & Tobago;XXX XXXX
1784;VC;Saint Vincent & the Grenadines 1784;VC;Saint Vincent & the Grenadines;XXX XXXX
1767;DM;Dominica 1767;DM;Dominica;XXX XXXX
1758;LC;Saint Lucia 1758;LC;Saint Lucia;XXX XXXX
1721;SX;Sint Maarten 1721;SX;Sint Maarten;XXX XXXX
1684;AS;American Samoa 1684;AS;American Samoa;XXX XXXX
1671;GU;Guam 1671;GU;Guam;XXX XXXX
1670;MP;Northern Mariana Islands 1670;MP;Northern Mariana Islands;XXX XXXX
1664;MS;Montserrat 1664;MS;Montserrat;XXX XXXX
1649;TC;Turks & Caicos Islands 1649;TC;Turks & Caicos Islands;XXX XXXX
1473;GD;Grenada 1473;GD;Grenada;XXX XXXX
1441;BM;Bermuda 1441;BM;Bermuda;XXX XXXX
1345;KY;Cayman Islands 1345;KY;Cayman Islands;XXX XXXX
1340;VI;US Virgin Islands 1340;VI;US Virgin Islands;XXX XXXX
1284;VG;British Virgin Islands 1284;VG;British Virgin Islands;XXX XXXX
1268;AG;Antigua & Barbuda 1268;AG;Antigua & Barbuda;XXX XXXX
1264;AI;Anguilla 1264;AI;Anguilla;XXX XXXX
1246;BB;Barbados 1246;BB;Barbados;XXX XXXX
1242;BS;Bahamas 1242;BS;Bahamas;XXX XXXX
998;UZ;Uzbekistan 998;UZ;Uzbekistan;XX XXXXXXX
996;KG;Kyrgyzstan 996;KG;Kyrgyzstan;XXX XXXXXX
995;GE;Georgia 995;GE;Georgia;XXX XXX XXX
994;AZ;Azerbaijan 994;AZ;Azerbaijan;XX XXX XXXX
993;TM;Turkmenistan 993;TM;Turkmenistan;XX XXXXXX
992;TJ;Tajikistan 992;TJ;Tajikistan;XX XXX XXXX
977;NP;Nepal 977;NP;Nepal;XX XXXX XXXX
976;MN;Mongolia 976;MN;Mongolia;XX XX XXXX
975;BT;Bhutan 975;BT;Bhutan;XX XXX XXX
974;QA;Qatar 974;QA;Qatar;XX XXX XXX
973;BH;Bahrain 973;BH;Bahrain;XXXX XXXX
972;IL;Israel 972;IL;Israel;XX XXX XXXX
971;AE;United Arab Emirates 971;AE;United Arab Emirates;XX XXX XXXX
970;PS;Palestine 970;PS;Palestine;XXX XX XXXX
968;OM;Oman 968;OM;Oman;XXXX XXXX
967;YE;Yemen 967;YE;Yemen;XXX XXX XXX
966;SA;Saudi Arabia 966;SA;Saudi Arabia;XX XXX XXXX
965;KW;Kuwait 965;KW;Kuwait;XXXX XXXX
964;IQ;Iraq 964;IQ;Iraq;XXX XXX XXXX
963;SY;Syrian Arab Republic 963;SY;Syria;XXX XXX XXX
962;JO;Jordan 962;JO;Jordan;X XXXX XXXX
961;LB;Lebanon 961;LB;Lebanon
960;MV;Maldives 960;MV;Maldives;XXX XXXX
886;TW;Taiwan 886;TW;Taiwan;XXX XXX XXX
880;BD;Bangladesh 880;BD;Bangladesh
856;LA;Laos 856;LA;Laos;XX XX XXX XXX
855;KH;Cambodia 855;KH;Cambodia
853;MO;Macau 853;MO;Macau;XXXX XXXX
852;HK;Hong Kong 852;HK;Hong Kong;X XXX XXXX
850;KP;North Korea 850;KP;North Korea
692;MH;Marshall Islands 692;MH;Marshall Islands
691;FM;Micronesia 691;FM;Micronesia
@ -67,166 +67,166 @@
676;TO;Tonga 676;TO;Tonga
675;PG;Papua New Guinea 675;PG;Papua New Guinea
674;NR;Nauru 674;NR;Nauru
673;BN;Brunei Darussalam 673;BN;Brunei Darussalam;XXX XXXX
672;NF;Norfolk Island 672;NF;Norfolk Island
670;TL;Timor-Leste 670;TL;Timor-Leste
599;BQ;Bonaire, Sint Eustatius & Saba 599;BQ;Bonaire, Sint Eustatius & Saba
599;CW;Curaçao 599;CW;Curaçao
598;UY;Uruguay 598;UY;Uruguay;X XXX XXXX
597;SR;Suriname 597;SR;Suriname;XXX XXXX
596;MQ;Martinique 596;MQ;Martinique
595;PY;Paraguay 595;PY;Paraguay;XXX XXX XXX
594;GF;French Guiana 594;GF;French Guiana
593;EC;Ecuador 593;EC;Ecuador;XX XXX XXXX
592;GY;Guyana 592;GY;Guyana
591;BO;Bolivia 591;BO;Bolivia;X XXX XXXX
590;GP;Guadeloupe 590;GP;Guadeloupe;XXX XX XX XX
509;HT;Haiti 509;HT;Haiti
508;PM;Saint Pierre & Miquelon 508;PM;Saint Pierre & Miquelon
507;PA;Panama 507;PA;Panama;XXXX XXXX
506;CR;Costa Rica 506;CR;Costa Rica;XXXX XXXX
505;NI;Nicaragua 505;NI;Nicaragua;XXXX XXXX
504;HN;Honduras 504;HN;Honduras;XXXX XXXX
503;SV;El Salvador 503;SV;El Salvador;XXXX XXXX
502;GT;Guatemala 502;GT;Guatemala;X XXX XXXX
501;BZ;Belize 501;BZ;Belize
500;FK;Falkland Islands 500;FK;Falkland Islands
423;LI;Liechtenstein 423;LI;Liechtenstein
421;SK;Slovakia 421;SK;Slovakia;XXX XXX XXX
420;CZ;Czech Republic 420;CZ;Czech Republic;XXX XXX XXX
389;MK;Macedonia 389;MK;Macedonia;XX XXX XXX
387;BA;Bosnia & Herzegovina 387;BA;Bosnia & Herzegovina;XX XXX XXX
386;SI;Slovenia 386;SI;Slovenia;XX XXX XXX
385;HR;Croatia 385;HR;Croatia
382;ME;Montenegro 382;ME;Montenegro
381;RS;Serbia 381;RS;Serbia;XX XXX XXXX
380;UA;Ukraine 380;UA;Ukraine;XX XXX XX XX
378;SM;San Marino 378;SM;San Marino;XXX XXX XXXX
377;MC;Monaco 377;MC;Monaco;XXXX XXXX
376;AD;Andorra 376;AD;Andorra;XX XX XX
375;BY;Belarus 375;BY;Belarus;XX XXX XXXX
374;AM;Armenia 374;AM;Armenia;XX XXX XXX
373;MD;Moldova 373;MD;Moldova;XX XXX XXX
372;EE;Estonia 372;EE;Estonia
371;LV;Latvia 371;LV;Latvia;XXX XXXXX
370;LT;Lithuania 370;LT;Lithuania;XXX XXXXX
359;BG;Bulgaria 359;BG;Bulgaria
358;FI;Finland 358;FI;Finland
357;CY;Cyprus 357;CY;Cyprus;XXXX XXXX
356;MT;Malta 356;MT;Malta;XX XX XX XX
355;AL;Albania 355;AL;Albania;XX XXX XXXX
354;IS;Iceland 354;IS;Iceland;XXX XXXX
353;IE;Ireland 353;IE;Ireland;XX XXX XXXX
352;LU;Luxembourg 352;LU;Luxembourg
351;PT;Portugal 351;PT;Portugal;X XXXX XXXX
350;GI;Gibraltar 350;GI;Gibraltar;XXXX XXXX
299;GL;Greenland 299;GL;Greenland;XXX XXX
298;FO;Faroe Islands 298;FO;Faroe Islands;XXX XXX
297;AW;Aruba 297;AW;Aruba;XXX XXXX
291;ER;Eritrea 291;ER;Eritrea;X XXX XXX
290;SH;Saint Helena 290;SH;Saint Helena;XX XXX
269;KM;Comoros 269;KM;Comoros;XXX XXXX
268;SZ;Swaziland 268;SZ;Swaziland;XXXX XXXX
267;BW;Botswana 267;BW;Botswana;XX XXX XXX
266;LS;Lesotho 266;LS;Lesotho;XX XXX XXX
265;MW;Malawi 265;MW;Malawi;77 XXX XXXX
264;NA;Namibia 264;NA;Namibia;XX XXX XXXX
263;ZW;Zimbabwe 263;ZW;Zimbabwe;XX XXX XXXX
262;RE;Réunion 262;RE;Réunion;XXX XXX XXX
261;MG;Madagascar 261;MG;Madagascar;XX XX XXX XX
260;ZM;Zambia 260;ZM;Zambia;XX XXX XXXX
258;MZ;Mozambique 258;MZ;Mozambique;XX XXX XXXX
257;BI;Burundi 257;BI;Burundi;XX XX XXXX
256;UG;Uganda 256;UG;Uganda;XX XXX XXXX
255;TZ;Tanzania 255;TZ;Tanzania;XX XXX XXXX
254;KE;Kenya 254;KE;Kenya;XXX XXX XXX
253;DJ;Djibouti 253;DJ;Djibouti;XX XX XX XX
252;SO;Somalia 252;SO;Somalia;XX XXX XXX
251;ET;Ethiopia 251;ET;Ethiopia;XX XXX XXXX
250;RW;Rwanda 250;RW;Rwanda;XXX XXX XXX
249;SD;Sudan 249;SD;Sudan;XX XXX XXXX
248;SC;Seychelles 248;SC;Seychelles;X XX XX XX
247;SH;Saint Helena 247;SH;Saint Helena;XXXX
246;IO;Diego Garcia 246;IO;Diego Garcia;XXX XXXX
245;GW;Guinea-Bissau 245;GW;Guinea-Bissau;XXX XXXX
244;AO;Angola 244;AO;Angola;XXX XXX XXX
243;CD;Congo (Dem. Rep.) 243;CD;Congo (Dem. Rep.);XX XXX XXXX
242;CG;Congo (Rep.) 242;CG;Congo (Rep.);XX XXX XXXX
241;GA;Gabon 241;GA;Gabon;X XX XX XX
240;GQ;Equatorial Guinea 240;GQ;Equatorial Guinea;XXX XXX XXX
239;ST;São Tomé & Príncipe 239;ST;São Tomé & Príncipe;XX XXXXX
238;CV;Cape Verde 238;CV;Cape Verde;XXX XXXX
237;CM;Cameroon 237;CM;Cameroon;XXXX XXXX
236;CF;Central African Rep. 236;CF;Central African Rep.;XX XX XX XX
235;TD;Chad 235;TD;Chad;XX XX XX XX
234;NG;Nigeria 234;NG;Nigeria
233;GH;Ghana 233;GH;Ghana
232;SL;Sierra Leone 232;SL;Sierra Leone;XX XXX XXX
231;LR;Liberia 231;LR;Liberia
230;MU;Mauritius 230;MU;Mauritius
229;BJ;Benin 229;BJ;Benin;XX XXX XXX
228;TG;Togo 228;TG;Togo;XX XXX XXX
227;NE;Niger 227;NE;Niger;XX XX XX XX
226;BF;Burkina Faso 226;BF;Burkina Faso;XX XX XX XX
225;CI;Côte d`Ivoire 225;CI;Côte d`Ivoire;XX XXX XXX
224;GN;Guinea 224;GN;Guinea;XXX XXX XXX
223;ML;Mali 223;ML;Mali;XXXX XXXX
222;MR;Mauritania 222;MR;Mauritania;XXXX XXXX
221;SN;Senegal 221;SN;Senegal;XX XXX XXXX
220;GM;Gambia 220;GM;Gambia;XXX XXXX
218;LY;Libya 218;LY;Libya;XX XXX XXXX
216;TN;Tunisia 216;TN;Tunisia;XX XXX XXX
213;DZ;Algeria 213;DZ;Algeria;XXX XX XX XX
212;MA;Morocco 212;MA;Morocco;XX XXX XXXX
211;SS;South Sudan 211;SS;South Sudan;XX XXX XXXX
98;IR;Iran 98;IR;Iran;XXX XXX XXXX
95;MM;Myanmar 95;MM;Myanmar
94;LK;Sri Lanka 94;LK;Sri Lanka;XX XXX XXXX
93;AF;Afghanistan 93;AF;Afghanistan;XXX XXX XXX
92;PK;Pakistan 92;PK;Pakistan;XXX XXX XXXX
91;IN;India 91;IN;India;XXXXX XXXXX
90;TR;Turkey 90;TR;Turkey;XXX XXX XXXX
86;CN;China 86;CN;China;XXX XXXX XXXX
84;VN;Vietnam 84;VN;Vietnam
82;KR;South Korea 82;KR;South Korea
81;JP;Japan 81;JP;Japan;XX XXXX XXXX
66;TH;Thailand 66;TH;Thailand;X XXXX XXXX
65;SG;Singapore 65;SG;Singapore;XXXX XXXX
64;NZ;New Zealand 64;NZ;New Zealand
63;PH;Philippines 63;PH;Philippines;XXX XXX XXXX
62;ID;Indonesia 62;ID;Indonesia
61;AU;Australia 61;AU;Australia;XXX XXX XXX
60;MY;Malaysia 60;MY;Malaysia
58;VE;Venezuela 58;VE;Venezuela;XXX XXX XXXX
57;CO;Colombia 57;CO;Colombia;XXX XXX XXXX
56;CL;Chile 56;CL;Chile;X XXXX XXXX
55;BR;Brazil 55;BR;Brazil;XX XXXXX XXXX
54;AR;Argentina 54;AR;Argentina
53;CU;Cuba 53;CU;Cuba;XXXX XXXX
52;MX;Mexico 52;MX;Mexico
51;PE;Peru 51;PE;Peru;XXX XXX XXX
49;DE;Germany 49;DE;Germany
48;PL;Poland 48;PL;Poland;XX XXX XXXX
47;NO;Norway 47;NO;Norway;XXXX XXXX
46;SE;Sweden 46;SE;Sweden;XX XXX XXXX
45;DK;Denmark 45;DK;Denmark;XXXX XXXX
44;GB;United Kingdom 44;GB;United Kingdom;XXXX XXXXXX
43;AT;Austria 43;AT;Austria
42;YL;Y-land 42;YL;Y-land
41;CH;Switzerland 41;CH;Switzerland;XX XXX XXXX
40;RO;Romania 40;RO;Romania;XXX XXX XXX
39;IT;Italy 39;IT;Italy
36;HU;Hungary 36;HU;Hungary;XXX XXX XXX
34;ES;Spain 34;ES;Spain;XXX XXX XXX
33;FR;France 33;FR;France;X XX XX XX XX
32;BE;Belgium 32;BE;Belgium;XXX XX XX XX
31;NL;Netherlands 31;NL;Netherlands;X XX XX XX XX
30;GR;Greece 30;GR;Greece;XXX XXX XXXX
27;ZA;South Africa 27;ZA;South Africa;XX XXX XXXX
20;EG;Egypt 20;EG;Egypt;XX XXXX XXXX
7;KZ;Kazakhstan 7;KZ;Kazakhstan;XXX XXX XX XX
7;RU;Russian Federation 7;RU;Russian Federation;XXX XXX XXXX
1;PR;Puerto Rico 1;PR;Puerto Rico;XXX XXX XXXX
1;DO;Dominican Rep. 1;DO;Dominican Rep.;XXX XXX XXXX
1;CA;Canada 1;CA;Canada;XXX XXX XXXX
1;US;USA 1;US;USA;XXX XXX XXXX

View File

@ -337,8 +337,11 @@ public class ApplicationLoader extends Application {
} }
private void initPlayServices() { private void initPlayServices() {
AndroidUtilities.runOnUIThread(new Runnable() {
@Override
public void run() {
if (checkPlayServices()) { if (checkPlayServices()) {
gcm = GoogleCloudMessaging.getInstance(this); gcm = GoogleCloudMessaging.getInstance(ApplicationLoader.this);
regid = getRegistrationId(); regid = getRegistrationId();
if (regid.length() == 0) { if (regid.length() == 0) {
@ -350,6 +353,8 @@ public class ApplicationLoader extends Application {
FileLog.d("tmessages", "No valid Google Play Services APK found."); FileLog.d("tmessages", "No valid Google Play Services APK found.");
} }
} }
}, 1000);
}
private boolean checkPlayServices() { private boolean checkPlayServices() {
int resultCode = GooglePlayServicesUtil.isGooglePlayServicesAvailable(this); int resultCode = GooglePlayServicesUtil.isGooglePlayServicesAvailable(this);

View File

@ -12,9 +12,12 @@ import android.os.Handler;
import android.os.Looper; import android.os.Looper;
import android.os.Message; import android.os.Message;
import java.util.concurrent.CountDownLatch;
public class DispatchQueue extends Thread { public class DispatchQueue extends Thread {
public volatile Handler handler = null;
private final Object handlerSyncObject = new Object(); private volatile Handler handler = null;
private CountDownLatch syncLatch = new CountDownLatch(1);
public DispatchQueue(final String threadName) { public DispatchQueue(final String threadName) {
setName(threadName); setName(threadName);
@ -22,40 +25,24 @@ public class DispatchQueue extends Thread {
} }
private void sendMessage(Message msg, int delay) { private void sendMessage(Message msg, int delay) {
if (handler == null) { try {
try { syncLatch.await();
synchronized (handlerSyncObject) {
handlerSyncObject.wait();
}
} catch (Throwable t) {
t.printStackTrace();
}
}
if (handler != null) {
if (delay <= 0) { if (delay <= 0) {
handler.sendMessage(msg); handler.sendMessage(msg);
} else { } else {
handler.sendMessageDelayed(msg, delay); handler.sendMessageDelayed(msg, delay);
} }
} catch (Exception e) {
FileLog.e("tmessages", e);
} }
} }
public void cancelRunnable(Runnable runnable) { public void cancelRunnable(Runnable runnable) {
if (handler == null) { try {
synchronized (handlerSyncObject) { syncLatch.await();
if (handler == null) {
try {
handlerSyncObject.wait();
} catch (Throwable t) {
t.printStackTrace();
}
}
}
}
if (handler != null) {
handler.removeCallbacks(runnable); handler.removeCallbacks(runnable);
} catch (Exception e) {
FileLog.e("tmessages", e);
} }
} }
@ -64,39 +51,32 @@ public class DispatchQueue extends Thread {
} }
public void postRunnable(Runnable runnable, long delay) { public void postRunnable(Runnable runnable, long delay) {
if (handler == null) { try {
synchronized (handlerSyncObject) { syncLatch.await();
if (handler == null) {
try {
handlerSyncObject.wait();
} catch (Throwable t) {
t.printStackTrace();
}
}
}
}
if (handler != null) {
if (delay <= 0) { if (delay <= 0) {
handler.post(runnable); handler.post(runnable);
} else { } else {
handler.postDelayed(runnable, delay); handler.postDelayed(runnable, delay);
} }
} catch (Exception e) {
FileLog.e("tmessages", e);
} }
} }
public void cleanupQueue() { public void cleanupQueue() {
if (handler != null) { try {
syncLatch.await();
handler.removeCallbacksAndMessages(null); handler.removeCallbacksAndMessages(null);
} catch (Exception e) {
FileLog.e("tmessages", e);
} }
} }
@Override
public void run() { public void run() {
Looper.prepare(); Looper.prepare();
synchronized (handlerSyncObject) { handler = new Handler();
handler = new Handler(); syncLatch.countDown();
handlerSyncObject.notify();
}
Looper.loop(); Looper.loop();
} }
} }

View File

@ -487,7 +487,7 @@ public class FileLoadOperation {
delegate.didFailedLoadingFile(FileLoadOperation.this, 2); delegate.didFailedLoadingFile(FileLoadOperation.this, 2);
} else { } else {
if (location != null) { if (location != null) {
FileLog.e("tmessages", "" + location + " id = " + location.id + " access_hash = " + location.access_hash + " volume_id = " + location.local_id + " secret = " + location.secret); FileLog.e("tmessages", "" + location + " id = " + location.id + " local_id = " + location.local_id + " access_hash = " + location.access_hash + " volume_id = " + location.volume_id + " secret = " + location.secret);
} }
cleanup(); cleanup();
delegate.didFailedLoadingFile(FileLoadOperation.this, 0); delegate.didFailedLoadingFile(FileLoadOperation.this, 0);

View File

@ -817,7 +817,8 @@ public class FileLoader {
fileLoaderQueue.postRunnable(new Runnable() { fileLoaderQueue.postRunnable(new Runnable() {
@Override @Override
public void run() { public void run() {
for (File file : files) { for (int a = 0; a < files.size(); a++) {
File file = files.get(a);
if (file.exists()) { if (file.exists()) {
try { try {
if (!file.delete()) { if (!file.delete()) {
@ -827,6 +828,16 @@ public class FileLoader {
FileLog.e("tmessages", e); FileLog.e("tmessages", e);
} }
} }
try {
File qFile = new File(file.getPath(), "q_" + file.getName());
if (qFile.exists()) {
if (!file.delete()) {
file.deleteOnExit();
}
}
} catch (Exception e) {
FileLog.e("tmessages", e);
}
} }
} }
}); });

View File

@ -9,6 +9,7 @@
package org.telegram.messenger; package org.telegram.messenger;
import android.util.Log; import android.util.Log;
import android.widget.Toast;
import org.telegram.messenger.time.FastDateFormat; import org.telegram.messenger.time.FastDateFormat;
@ -68,6 +69,9 @@ public class FileLog {
} }
public static String getNetworkLogPath() { public static String getNetworkLogPath() {
if (!BuildVars.DEBUG_VERSION) {
return "";
}
try { try {
File sdCard = ApplicationLoader.applicationContext.getExternalFilesDir(null); File sdCard = ApplicationLoader.applicationContext.getExternalFilesDir(null);
if (sdCard == null) { if (sdCard == null) {
@ -208,5 +212,14 @@ public class FileLog {
} }
file.delete(); file.delete();
} }
//plus
final int i = files.length - 1;
AndroidUtilities.runOnUIThread(new Runnable() {
@Override
public void run() {
Toast toast = Toast.makeText(ApplicationLoader.applicationContext, i + " " + LocaleController.getString("ClearLogsMsg", R.string.ClearLogsMsg), Toast.LENGTH_SHORT);
toast.show();
}
});
} }
} }

View File

@ -41,7 +41,13 @@ public class UserConfig {
public static boolean useFingerprint = true; public static boolean useFingerprint = true;
public static int lastUpdateVersion; public static int lastUpdateVersion;
public static int lastContactsSyncTime; public static int lastContactsSyncTime;
public static boolean channelsLoaded = false;
public static int migrateOffsetId = -1;
public static int migrateOffsetDate = -1;
public static int migrateOffsetUserId = -1;
public static int migrateOffsetChatId = -1;
public static int migrateOffsetChannelId = -1;
public static long migrateOffsetAccess = -1;
public static int getNewMessageId() { public static int getNewMessageId() {
int id; int id;
@ -79,9 +85,17 @@ public class UserConfig {
editor.putInt("lastPauseTime", lastPauseTime); editor.putInt("lastPauseTime", lastPauseTime);
editor.putInt("lastUpdateVersion", lastUpdateVersion); editor.putInt("lastUpdateVersion", lastUpdateVersion);
editor.putInt("lastContactsSyncTime", lastContactsSyncTime); editor.putInt("lastContactsSyncTime", lastContactsSyncTime);
editor.putBoolean("channelsLoaded", channelsLoaded);
editor.putBoolean("useFingerprint", useFingerprint); editor.putBoolean("useFingerprint", useFingerprint);
editor.putInt("migrateOffsetId", migrateOffsetId);
if (migrateOffsetId != -1) {
editor.putInt("migrateOffsetDate", migrateOffsetDate);
editor.putInt("migrateOffsetUserId", migrateOffsetUserId);
editor.putInt("migrateOffsetChatId", migrateOffsetChatId);
editor.putInt("migrateOffsetChannelId", migrateOffsetChannelId);
editor.putLong("migrateOffsetAccess", migrateOffsetAccess);
}
if (currentUser != null) { if (currentUser != null) {
if (withFile) { if (withFile) {
SerializedData data = new SerializedData(); SerializedData data = new SerializedData();
@ -212,7 +226,16 @@ public class UserConfig {
useFingerprint = preferences.getBoolean("useFingerprint", true); useFingerprint = preferences.getBoolean("useFingerprint", true);
lastUpdateVersion = preferences.getInt("lastUpdateVersion", 511); lastUpdateVersion = preferences.getInt("lastUpdateVersion", 511);
lastContactsSyncTime = preferences.getInt("lastContactsSyncTime", (int) (System.currentTimeMillis() / 1000) - 23 * 60 * 60); lastContactsSyncTime = preferences.getInt("lastContactsSyncTime", (int) (System.currentTimeMillis() / 1000) - 23 * 60 * 60);
channelsLoaded = preferences.getBoolean("channelsLoaded", false);
migrateOffsetId = preferences.getInt("migrateOffsetId", 0);
if (migrateOffsetId != -1) {
migrateOffsetDate = preferences.getInt("migrateOffsetDate", 0);
migrateOffsetUserId = preferences.getInt("migrateOffsetUserId", 0);
migrateOffsetChatId = preferences.getInt("migrateOffsetChatId", 0);
migrateOffsetChannelId = preferences.getInt("migrateOffsetChannelId", 0);
migrateOffsetAccess = preferences.getLong("migrateOffsetAccess", 0);
}
String user = preferences.getString("user", null); String user = preferences.getString("user", null);
if (user != null) { if (user != null) {
byte[] userBytes = Base64.decode(user, Base64.DEFAULT); byte[] userBytes = Base64.decode(user, Base64.DEFAULT);
@ -277,7 +300,12 @@ public class UserConfig {
lastBroadcastId = -1; lastBroadcastId = -1;
saveIncomingPhotos = false; saveIncomingPhotos = false;
blockedUsersLoaded = false; blockedUsersLoaded = false;
channelsLoaded = false; migrateOffsetId = -1;
migrateOffsetDate = -1;
migrateOffsetUserId = -1;
migrateOffsetChatId = -1;
migrateOffsetChannelId = -1;
migrateOffsetAccess = -1;
appLocked = false; appLocked = false;
passcodeType = 0; passcodeType = 0;
passcodeHash = ""; passcodeHash = "";

View File

@ -264,7 +264,7 @@ public class Utilities {
} }
//MIO //plus
public static void restartApp(){ public static void restartApp(){
Intent mRestartApp = new Intent(ApplicationLoader.applicationContext, LaunchActivity.class); Intent mRestartApp = new Intent(ApplicationLoader.applicationContext, LaunchActivity.class);
int mPendingIntentId = 123456; int mPendingIntentId = 123456;

View File

@ -896,7 +896,7 @@ public class ActionBarLayout extends FrameLayout {
onCloseAnimationEndRunnable = new Runnable() { onCloseAnimationEndRunnable = new Runnable() {
@Override @Override
public void run() { public void run() {
removeFragmentFromStack(currentFragment); removeFragmentFromStackInternal(currentFragment);
setVisibility(GONE); setVisibility(GONE);
if (backgroundView != null) { if (backgroundView != null) {
backgroundView.setVisibility(GONE); backgroundView.setVisibility(GONE);
@ -935,7 +935,7 @@ public class ActionBarLayout extends FrameLayout {
}); });
currentAnimation.start(); currentAnimation.start();
} else { } else {
removeFragmentFromStack(currentFragment); removeFragmentFromStackInternal(currentFragment);
setVisibility(GONE); setVisibility(GONE);
if (backgroundView != null) { if (backgroundView != null) {
backgroundView.setVisibility(GONE); backgroundView.setVisibility(GONE);
@ -998,16 +998,24 @@ public class ActionBarLayout extends FrameLayout {
} }
} }
public void removeFragmentFromStack(BaseFragment fragment) { private void removeFragmentFromStackInternal(BaseFragment fragment) {
fragment.onPause(); fragment.onPause();
fragment.onFragmentDestroy(); fragment.onFragmentDestroy();
fragment.setParentLayout(null); fragment.setParentLayout(null);
fragmentsStack.remove(fragment); fragmentsStack.remove(fragment);
} }
public void removeFragmentFromStack(BaseFragment fragment) {
if (useAlphaAnimations && fragmentsStack.size() == 1 && AndroidUtilities.isTablet()) {
closeLastFragment(true);
} else {
removeFragmentFromStackInternal(fragment);
}
}
public void removeAllFragments() { public void removeAllFragments() {
for (int a = 0; a < fragmentsStack.size(); a++) { for (int a = 0; a < fragmentsStack.size(); a++) {
removeFragmentFromStack(fragmentsStack.get(a)); removeFragmentFromStackInternal(fragmentsStack.get(a));
a--; a--;
} }
} }

View File

@ -289,7 +289,6 @@ public class ActionBarMenuItem extends FrameLayoutFixed {
} }
if (popupWindow == null) { if (popupWindow == null) {
popupWindow = new ActionBarPopupWindow(popupLayout, LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT); popupWindow = new ActionBarPopupWindow(popupLayout, LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT);
//popupWindow.setBackgroundDrawable(new BitmapDrawable());
if (Build.VERSION.SDK_INT >= 19) { if (Build.VERSION.SDK_INT >= 19) {
popupWindow.setAnimationStyle(0); popupWindow.setAnimationStyle(0);
} else { } else {

View File

@ -90,13 +90,22 @@ public class ActionBarPopupWindow extends PopupWindow {
setPadding(AndroidUtilities.dp(8), AndroidUtilities.dp(8), AndroidUtilities.dp(8), AndroidUtilities.dp(8)); setPadding(AndroidUtilities.dp(8), AndroidUtilities.dp(8), AndroidUtilities.dp(8), AndroidUtilities.dp(8));
setWillNotDraw(false); setWillNotDraw(false);
scrollView = new ScrollView(context); try {
scrollView.setVerticalScrollBarEnabled(false); scrollView = new ScrollView(context);
addView(scrollView, LayoutHelper.createFrame(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT)); scrollView.setVerticalScrollBarEnabled(false);
addView(scrollView, LayoutHelper.createFrame(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT));
} catch (Throwable e) {
FileLog.e("tmessages", e);
}
linearLayout = new LinearLayout(context); linearLayout = new LinearLayout(context);
linearLayout.setOrientation(LinearLayout.VERTICAL); linearLayout.setOrientation(LinearLayout.VERTICAL);
scrollView.addView(linearLayout, new ScrollView.LayoutParams(ViewGroup.LayoutParams.WRAP_CONTENT, ViewGroup.LayoutParams.WRAP_CONTENT)); if (scrollView != null) {
scrollView.addView(linearLayout, new ScrollView.LayoutParams(ViewGroup.LayoutParams.WRAP_CONTENT, ViewGroup.LayoutParams.WRAP_CONTENT));
} else {
addView(linearLayout, LayoutHelper.createFrame(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT));
}
} }
public void setShowedFromBotton(boolean value) { public void setShowedFromBotton(boolean value) {
@ -215,7 +224,9 @@ public class ActionBarPopupWindow extends PopupWindow {
} }
public void scrollToTop() { public void scrollToTop() {
scrollView.scrollTo(0, 0); if (scrollView != null) {
scrollView.scrollTo(0, 0);
}
} }
} }
@ -374,6 +385,7 @@ public class ActionBarPopupWindow extends PopupWindow {
} }
public void dismiss(boolean animated) { public void dismiss(boolean animated) {
setFocusable(false);
if (animationEnabled && animated) { if (animationEnabled && animated) {
if (windowAnimatorSet != null) { if (windowAnimatorSet != null) {
windowAnimatorSet.cancel(); windowAnimatorSet.cancel();
@ -414,7 +426,6 @@ public class ActionBarPopupWindow extends PopupWindow {
}); });
windowAnimatorSet.start(); windowAnimatorSet.start();
} else { } else {
setFocusable(false);
try { try {
super.dismiss(); super.dismiss();
} catch (Exception e) { } catch (Exception e) {

View File

@ -41,7 +41,7 @@ public class BaseSearchAdapter extends BaseFragmentAdapter {
protected HashMap<String, HashtagObject> hashtagsByText; protected HashMap<String, HashtagObject> hashtagsByText;
protected boolean hashtagsLoadedFromDb = false; protected boolean hashtagsLoadedFromDb = false;
public void queryServerSearch(final String query, final boolean allowChats) { public void queryServerSearch(final String query, final boolean allowChats, final boolean allowBots) {
if (reqId != 0) { if (reqId != 0) {
ConnectionsManager.getInstance().cancelRequest(reqId, true); ConnectionsManager.getInstance().cancelRequest(reqId, true);
reqId = 0; reqId = 0;
@ -72,6 +72,9 @@ public class BaseSearchAdapter extends BaseFragmentAdapter {
} }
} }
for (int a = 0; a < res.users.size(); a++) { for (int a = 0; a < res.users.size(); a++) {
if (!allowBots && res.users.get(a).bot) {
continue;
}
globalSearch.add(res.users.get(a)); globalSearch.add(res.users.get(a));
} }
lastFoundUsername = query; lastFoundUsername = query;

View File

@ -275,7 +275,7 @@ public class ContactsAdapter extends BaseSectionsAdapter {
} }
} else if (type == 0) { } else if (type == 0) {
if (convertView == null) { if (convertView == null) {
convertView = new UserCell(mContext, 58); convertView = new UserCell(mContext, 58, 1);
convertView.setTag("Contacts"); convertView.setTag("Contacts");
} }
updateViewColor(convertView); updateViewColor(convertView);

View File

@ -49,7 +49,7 @@ public class DialogsAdapter extends RecyclerView.Adapter {
public boolean isDataSetChanged() { public boolean isDataSetChanged() {
int current = currentCount; int current = currentCount;
return current != getItemCount(); return current != getItemCount() || current == 1;
} }
private ArrayList<TLRPC.Dialog> getDialogsArray() { private ArrayList<TLRPC.Dialog> getDialogsArray() {

View File

@ -18,6 +18,7 @@ import org.telegram.SQLite.SQLiteCursor;
import org.telegram.SQLite.SQLitePreparedStatement; import org.telegram.SQLite.SQLitePreparedStatement;
import org.telegram.messenger.AndroidUtilities; import org.telegram.messenger.AndroidUtilities;
import org.telegram.messenger.ApplicationLoader; import org.telegram.messenger.ApplicationLoader;
import org.telegram.messenger.ChatObject;
import org.telegram.messenger.ContactsController; import org.telegram.messenger.ContactsController;
import org.telegram.messenger.LocaleController; import org.telegram.messenger.LocaleController;
import org.telegram.messenger.MessageObject; import org.telegram.messenger.MessageObject;
@ -130,15 +131,29 @@ public class DialogsSearchAdapter extends BaseSearchAdapterRecycler {
} }
return; return;
} }
final TLRPC.TL_messages_search req = new TLRPC.TL_messages_search();
final TLRPC.TL_messages_searchGlobal req = new TLRPC.TL_messages_searchGlobal();
req.limit = 20; req.limit = 20;
req.peer = new TLRPC.TL_inputPeerEmpty();
req.q = query; req.q = query;
if (lastMessagesSearchString != null && query.equals(lastMessagesSearchString) && !searchResultMessages.isEmpty()) { if (lastMessagesSearchString != null && query.equals(lastMessagesSearchString) && !searchResultMessages.isEmpty()) {
req.max_id = searchResultMessages.get(searchResultMessages.size() - 1).getId(); MessageObject lastMessage = searchResultMessages.get(searchResultMessages.size() - 1);
req.offset_id = lastMessage.getId();
req.offset_date = lastMessage.messageOwner.date;
int id;
if (lastMessage.messageOwner.to_id.channel_id != 0) {
id = -lastMessage.messageOwner.to_id.channel_id;
} else if (lastMessage.messageOwner.to_id.chat_id != 0) {
id = -lastMessage.messageOwner.to_id.chat_id;
} else {
id = lastMessage.messageOwner.to_id.user_id;
}
req.offset_peer = MessagesController.getInputPeer(id);
} else {
req.offset_date = 0;
req.offset_id = 0;
req.offset_peer = new TLRPC.TL_inputPeerEmpty();
} }
lastMessagesSearchString = query; lastMessagesSearchString = query;
req.filter = new TLRPC.TL_inputMessagesFilterEmpty();
final int currentReqId = ++lastReqId; final int currentReqId = ++lastReqId;
if (delegate != null) { if (delegate != null) {
delegate.searchStateChanged(true); delegate.searchStateChanged(true);
@ -155,7 +170,7 @@ public class DialogsSearchAdapter extends BaseSearchAdapterRecycler {
MessagesStorage.getInstance().putUsersAndChats(res.users, res.chats, true, true); MessagesStorage.getInstance().putUsersAndChats(res.users, res.chats, true, true);
MessagesController.getInstance().putUsers(res.users, false); MessagesController.getInstance().putUsers(res.users, false);
MessagesController.getInstance().putChats(res.chats, false); MessagesController.getInstance().putChats(res.chats, false);
if (req.max_id == 0) { if (req.offset_id == 0) {
searchResultMessages.clear(); searchResultMessages.clear();
} }
for (TLRPC.Message message : res.messages) { for (TLRPC.Message message : res.messages) {
@ -260,9 +275,16 @@ public class DialogsSearchAdapter extends BaseSearchAdapterRecycler {
} else { } else {
did = AndroidUtilities.makeBroadcastId(chat.id); did = AndroidUtilities.makeBroadcastId(chat.id);
} }
if (chat.migrated_to != null) {
RecentSearchObject recentSearchObject = hashMap.remove(did);
if (recentSearchObject != null) {
arrayList.remove(recentSearchObject);
}
} else {
hashMap.get(did).object = chat; hashMap.get(did).object = chat;
} }
} }
}
if (!usersToLoad.isEmpty()) { if (!usersToLoad.isEmpty()) {
MessagesStorage.getInstance().getUsersInternal(TextUtils.join(",", usersToLoad), users); MessagesStorage.getInstance().getUsersInternal(TextUtils.join(",", usersToLoad), users);
@ -393,7 +415,7 @@ public class DialogsSearchAdapter extends BaseSearchAdapterRecycler {
int resultCount = 0; int resultCount = 0;
HashMap<Long, DialogSearchResult> dialogsResult = new HashMap<>(); HashMap<Long, DialogSearchResult> dialogsResult = new HashMap<>();
SQLiteCursor cursor = MessagesStorage.getInstance().getDatabase().queryFinalized("SELECT did, date FROM dialogs ORDER BY date DESC LIMIT 200"); SQLiteCursor cursor = MessagesStorage.getInstance().getDatabase().queryFinalized("SELECT did, date FROM dialogs ORDER BY date DESC LIMIT 400");
while (cursor.next()) { while (cursor.next()) {
long id = cursor.longValue(0); long id = cursor.longValue(0);
DialogSearchResult dialogSearchResult = new DialogSearchResult(); DialogSearchResult dialogSearchResult = new DialogSearchResult();
@ -483,6 +505,7 @@ public class DialogsSearchAdapter extends BaseSearchAdapterRecycler {
NativeByteBuffer data = new NativeByteBuffer(cursor.byteArrayLength(0)); NativeByteBuffer data = new NativeByteBuffer(cursor.byteArrayLength(0));
if (data != null && cursor.byteBufferValue(0, data) != 0) { if (data != null && cursor.byteBufferValue(0, data) != 0) {
TLRPC.Chat chat = TLRPC.Chat.TLdeserialize(data, data.readInt32(false), false); TLRPC.Chat chat = TLRPC.Chat.TLdeserialize(data, data.readInt32(false), false);
if (!(chat == null || chat.deactivated || ChatObject.isChannel(chat) && ChatObject.isNotInChat(chat))) {
long dialog_id; long dialog_id;
if (chat.id > 0) { if (chat.id > 0) {
dialog_id = -chat.id; dialog_id = -chat.id;
@ -494,6 +517,7 @@ public class DialogsSearchAdapter extends BaseSearchAdapterRecycler {
dialogSearchResult.object = chat; dialogSearchResult.object = chat;
resultCount++; resultCount++;
} }
}
data.reuse(); data.reuse();
break; break;
} }
@ -591,7 +615,8 @@ public class DialogsSearchAdapter extends BaseSearchAdapterRecycler {
ArrayList<TLObject> resultArray = new ArrayList<>(); ArrayList<TLObject> resultArray = new ArrayList<>();
ArrayList<CharSequence> resultArrayNames = new ArrayList<>(); ArrayList<CharSequence> resultArrayNames = new ArrayList<>();
for (DialogSearchResult dialogSearchResult : searchResults) { for (int a = 0; a < searchResults.size(); a++) {
DialogSearchResult dialogSearchResult = searchResults.get(a);
resultArray.add(dialogSearchResult.object); resultArray.add(dialogSearchResult.object);
resultArrayNames.add(dialogSearchResult.name); resultArrayNames.add(dialogSearchResult.name);
} }
@ -799,7 +824,19 @@ public class DialogsSearchAdapter extends BaseSearchAdapterRecycler {
public Object getItem(int i) { public Object getItem(int i) {
if (needMessagesSearch != 2 && (lastSearchText == null || lastSearchText.length() == 0) && !recentSearchObjects.isEmpty()) { if (needMessagesSearch != 2 && (lastSearchText == null || lastSearchText.length() == 0) && !recentSearchObjects.isEmpty()) {
if (i > 0 && i - 1 < recentSearchObjects.size()) { if (i > 0 && i - 1 < recentSearchObjects.size()) {
return recentSearchObjects.get(i - 1).object; TLObject object = recentSearchObjects.get(i - 1).object;
if (object instanceof TLRPC.User) {
TLRPC.User user = MessagesController.getInstance().getUser(((TLRPC.User) object).id);
if (user != null) {
object = user;
}
} else if (object instanceof TLRPC.Chat) {
TLRPC.Chat chat = MessagesController.getInstance().getChat(((TLRPC.Chat) object).id);
if (chat != null) {
object = chat;
}
}
return object;
} else { } else {
return null; return null;
} }

View File

@ -166,8 +166,9 @@ public class MentionsAdapter extends BaseSearchAdapter {
} }
String usernameString = result.toString().toLowerCase(); String usernameString = result.toString().toLowerCase();
ArrayList<TLRPC.User> newResult = new ArrayList<>(); ArrayList<TLRPC.User> newResult = new ArrayList<>();
if (info instanceof TLRPC.TL_chatFull) { if (info.participants != null) {
for (TLRPC.TL_chatParticipant chatParticipant : info.participants.participants) { for (int a = 0; a < info.participants.participants.size(); a++) {
TLRPC.ChatParticipant chatParticipant = info.participants.participants.get(a);
TLRPC.User user = MessagesController.getInstance().getUser(chatParticipant.user_id); TLRPC.User user = MessagesController.getInstance().getUser(chatParticipant.user_id);
if (user == null || UserObject.isUserSelf(user)) { if (user == null || UserObject.isUserSelf(user)) {
continue; continue;
@ -220,11 +221,13 @@ public class MentionsAdapter extends BaseSearchAdapter {
ArrayList<TLRPC.User> newResultUsers = new ArrayList<>(); ArrayList<TLRPC.User> newResultUsers = new ArrayList<>();
String command = result.toString().toLowerCase(); String command = result.toString().toLowerCase();
for (HashMap.Entry<Integer, TLRPC.BotInfo> entry : botInfo.entrySet()) { for (HashMap.Entry<Integer, TLRPC.BotInfo> entry : botInfo.entrySet()) {
for (TLRPC.TL_botCommand botCommand : entry.getValue().commands) { TLRPC.BotInfo botInfo = entry.getValue();
for (int a = 0; a < botInfo.commands.size(); a++) {
TLRPC.TL_botCommand botCommand = botInfo.commands.get(a);
if (botCommand != null && botCommand.command != null && botCommand.command.startsWith(command)) { if (botCommand != null && botCommand.command != null && botCommand.command.startsWith(command)) {
newResult.add("/" + botCommand.command); newResult.add("/" + botCommand.command);
newResultHelp.add(botCommand.description); newResultHelp.add(botCommand.description);
newResultUsers.add(MessagesController.getInstance().getUser(entry.getValue().user_id)); newResultUsers.add(MessagesController.getInstance().getUser(botInfo.user_id));
} }
} }
} }
@ -311,8 +314,12 @@ public class MentionsAdapter extends BaseSearchAdapter {
if (i < 0 || i >= searchResultCommands.size()) { if (i < 0 || i >= searchResultCommands.size()) {
return null; return null;
} }
if (searchResultCommandsUsers != null && botsCount != 1) { if (searchResultCommandsUsers != null && (botsCount != 1 || info instanceof TLRPC.TL_channelFull)) {
return String.format("%s@%s", searchResultCommands.get(i), searchResultCommandsUsers.get(i).username); if (searchResultCommandsUsers.get(i) != null) {
return String.format("%s@%s", searchResultCommands.get(i), searchResultCommandsUsers.get(i) != null ? searchResultCommandsUsers.get(i).username : "");
} else {
return String.format("%s", searchResultCommands.get(i));
}
} }
return searchResultCommands.get(i); return searchResultCommands.get(i);
} }
@ -338,7 +345,7 @@ public class MentionsAdapter extends BaseSearchAdapter {
} else if (searchResultHashtags != null) { } else if (searchResultHashtags != null) {
((MentionCell) view).setText(searchResultHashtags.get(i)); ((MentionCell) view).setText(searchResultHashtags.get(i));
} else if (searchResultCommands != null) { } else if (searchResultCommands != null) {
((MentionCell) view).setBotCommand(searchResultCommands.get(i), searchResultCommandsHelp.get(i), searchResultCommandsUsers.get(i)); ((MentionCell) view).setBotCommand(searchResultCommands.get(i), searchResultCommandsHelp.get(i), searchResultCommandsUsers != null ? searchResultCommandsUsers.get(i) : null);
} }
return view; return view;
} }

View File

@ -43,13 +43,15 @@ public class SearchAdapter extends BaseSearchAdapter {
private boolean useUserCell; private boolean useUserCell;
private boolean onlyMutual; private boolean onlyMutual;
private boolean allowChats; private boolean allowChats;
private boolean allowBots;
public SearchAdapter(Context context, HashMap<Integer, TLRPC.User> arg1, boolean usernameSearch, boolean mutual, boolean chats) { public SearchAdapter(Context context, HashMap<Integer, TLRPC.User> arg1, boolean usernameSearch, boolean mutual, boolean chats, boolean bots) {
mContext = context; mContext = context;
ignoreUsers = arg1; ignoreUsers = arg1;
onlyMutual = mutual; onlyMutual = mutual;
allowUsernameSearch = usernameSearch; allowUsernameSearch = usernameSearch;
allowChats = chats; allowChats = chats;
allowBots = bots;
} }
public void setCheckedMap(HashMap<Integer, ?> map) { public void setCheckedMap(HashMap<Integer, ?> map) {
@ -72,7 +74,7 @@ public class SearchAdapter extends BaseSearchAdapter {
searchResult.clear(); searchResult.clear();
searchResultNames.clear(); searchResultNames.clear();
if (allowUsernameSearch) { if (allowUsernameSearch) {
queryServerSearch(null, allowChats); queryServerSearch(null, allowChats, allowBots);
} }
notifyDataSetChanged(); notifyDataSetChanged();
} else { } else {
@ -97,7 +99,7 @@ public class SearchAdapter extends BaseSearchAdapter {
@Override @Override
public void run() { public void run() {
if (allowUsernameSearch) { if (allowUsernameSearch) {
queryServerSearch(query, allowChats); queryServerSearch(query, allowChats, allowBots);
} }
final ArrayList<TLRPC.TL_contact> contactsCopy = new ArrayList<>(); final ArrayList<TLRPC.TL_contact> contactsCopy = new ArrayList<>();
contactsCopy.addAll(ContactsController.getInstance().contacts); contactsCopy.addAll(ContactsController.getInstance().contacts);
@ -122,9 +124,10 @@ public class SearchAdapter extends BaseSearchAdapter {
ArrayList<TLRPC.User> resultArray = new ArrayList<>(); ArrayList<TLRPC.User> resultArray = new ArrayList<>();
ArrayList<CharSequence> resultArrayNames = new ArrayList<>(); ArrayList<CharSequence> resultArrayNames = new ArrayList<>();
for (TLRPC.TL_contact contact : contactsCopy) { for (int a = 0; a < contactsCopy.size(); a++) {
TLRPC.TL_contact contact = contactsCopy.get(a);
TLRPC.User user = MessagesController.getInstance().getUser(contact.user_id); TLRPC.User user = MessagesController.getInstance().getUser(contact.user_id);
if (user.id == UserConfig.getClientUserId() || onlyMutual && (user.flags & TLRPC.USER_FLAG_MUTUAL_CONTACT) == 0) { if (user.id == UserConfig.getClientUserId() || onlyMutual && !user.mutual_contact) {
continue; continue;
} }
@ -235,7 +238,7 @@ public class SearchAdapter extends BaseSearchAdapter {
} else { } else {
if (view == null) { if (view == null) {
if (useUserCell) { if (useUserCell) {
view = new UserCell(mContext, 1); view = new UserCell(mContext, 1, 1);
if (checkedMap != null) { if (checkedMap != null) {
((UserCell) view).setChecked(false, false); ((UserCell) view).setChecked(false, false);
} }

View File

@ -288,7 +288,7 @@ public class BlockedUsersActivity extends BaseFragment implements NotificationCe
SharedPreferences preferences = ApplicationLoader.applicationContext.getSharedPreferences(AndroidUtilities.THEME_PREFS, AndroidUtilities.THEME_PREFS_MODE); SharedPreferences preferences = ApplicationLoader.applicationContext.getSharedPreferences(AndroidUtilities.THEME_PREFS, AndroidUtilities.THEME_PREFS_MODE);
if (type == 0) { if (type == 0) {
if (view == null) { if (view == null) {
view = new UserCell(mContext, 1); view = new UserCell(mContext, 1, 0);
view.setTag("Pref"); view.setTag("Pref");
} }
((UserCell) view).setNameColor(preferences.getInt("prefTitleColor", 0xff212121)); ((UserCell) view).setNameColor(preferences.getInt("prefTitleColor", 0xff212121));

View File

@ -1,75 +0,0 @@
/*
* This is the source code of Telegram for Android v. 3.x.x
* It is licensed under GNU GPL v. 2 or later.
* You should have received a copy of the license in this archive (see LICENSE).
*
* Copyright Nikolai Kudashov, 2013-2015.
*/
package org.telegram.ui.Cells;
import android.content.Context;
import android.graphics.PorterDuff;
import android.graphics.drawable.Drawable;
import android.os.Build;
import android.view.Gravity;
import android.view.MotionEvent;
import android.widget.FrameLayout;
import android.widget.ImageView;
import org.telegram.messenger.AndroidUtilities;
import org.telegram.messenger.LocaleController;
import org.telegram.messenger.R;
import org.telegram.ui.Components.LayoutHelper;
import org.telegram.ui.Components.SimpleTextView;
public class AddMemberCell extends FrameLayout {
private SimpleTextView textView;
private ImageView imageView;
public AddMemberCell(Context context) {
super(context);
//ImageView imageView = new ImageView(context);
imageView = new ImageView(context);
imageView.setImageResource(R.drawable.addmember);
imageView.setScaleType(ImageView.ScaleType.CENTER);
addView(imageView, LayoutHelper.createFrame(48, 48, (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT) | Gravity.TOP, LocaleController.isRTL ? 0 : 68, 8, LocaleController.isRTL ? 68 : 0, 0));
textView = new SimpleTextView(context);
textView.setTextColor(0xff212121);
textView.setTextSize(17);
textView.setGravity((LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT) | Gravity.TOP);
addView(textView, LayoutHelper.createFrame(LayoutHelper.MATCH_PARENT, 20, (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT) | Gravity.TOP, LocaleController.isRTL ? 28 : 129, 22.5f, LocaleController.isRTL ? 129 : 28, 0));
}
@Override
public boolean onTouchEvent(MotionEvent event) {
if (Build.VERSION.SDK_INT >= 21 && getBackground() != null) {
if (event.getAction() == MotionEvent.ACTION_DOWN || event.getAction() == MotionEvent.ACTION_MOVE) {
getBackground().setHotspot(event.getX(), event.getY());
}
}
return super.onTouchEvent(event);
}
@Override
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
super.onMeasure(MeasureSpec.makeMeasureSpec(MeasureSpec.getSize(widthMeasureSpec), MeasureSpec.EXACTLY), MeasureSpec.makeMeasureSpec(AndroidUtilities.dp(64), MeasureSpec.EXACTLY));
}
public void setTextColor(int color) {
textView.setTextColor(color);
}
public void setDrawableColor(int color) {
Drawable d = getResources().getDrawable(R.drawable.addmember);
d.setColorFilter(color, PorterDuff.Mode.SRC_IN);
imageView.setImageDrawable(d);
}
public void setText(String text) {
textView.setText(text);
}
}

View File

@ -1,5 +1,5 @@
/* /*
* This is the source code of Telegram for Android v. 3.x.x * This is the source code of Telegram for Android v. 3.x.x.
* It is licensed under GNU GPL v. 2 or later. * It is licensed under GNU GPL v. 2 or later.
* You should have received a copy of the license in this archive (see LICENSE). * You should have received a copy of the license in this archive (see LICENSE).
* *

View File

@ -53,6 +53,7 @@ public class ChatBaseCell extends BaseCell implements MediaController.FileDownlo
void didPressUrl(MessageObject messageObject, ClickableSpan url, boolean longPress); void didPressUrl(MessageObject messageObject, ClickableSpan url, boolean longPress);
void needOpenWebView(String url, String title, String originalUrl, int w, int h); void needOpenWebView(String url, String title, String originalUrl, int w, int h);
void didClickedImage(ChatBaseCell cell); void didClickedImage(ChatBaseCell cell);
void didPressShare(ChatBaseCell cell);
boolean canPerformActions(); boolean canPerformActions();
} }
@ -106,6 +107,11 @@ public class ChatBaseCell extends BaseCell implements MediaController.FileDownlo
private boolean replyPressed = false; private boolean replyPressed = false;
private TLRPC.FileLocation currentReplyPhoto; private TLRPC.FileLocation currentReplyPhoto;
private boolean drawShareButton;
private boolean sharePressed;
private int shareStartX;
private int shareStartY;
private StaticLayout nameLayout; private StaticLayout nameLayout;
protected int nameWidth; protected int nameWidth;
private float nameOffsetX = 0; private float nameOffsetX = 0;
@ -382,7 +388,7 @@ public class ChatBaseCell extends BaseCell implements MediaController.FileDownlo
} }
protected void measureTime(MessageObject messageObject) { protected void measureTime(MessageObject messageObject) {
currentTimeString = LocaleController.formatterDay.format((long) (messageObject.messageOwner.date) * 1000); currentTimeString = LocaleController.getInstance().formatterDay.format((long) (messageObject.messageOwner.date) * 1000);
timeTextWidth = timeWidth = (int) Math.ceil(timeMediaPaint.measureText(currentTimeString)); timeTextWidth = timeWidth = (int) Math.ceil(timeMediaPaint.measureText(currentTimeString));
if ((messageObject.messageOwner.flags & TLRPC.MESSAGE_FLAG_HAS_VIEWS) != 0) { if ((messageObject.messageOwner.flags & TLRPC.MESSAGE_FLAG_HAS_VIEWS) != 0) {
currentViewsString = String.format("%s", LocaleController.formatShortNumber(Math.max(1, messageObject.messageOwner.views), null)); currentViewsString = String.format("%s", LocaleController.formatShortNumber(Math.max(1, messageObject.messageOwner.views), null));
@ -399,6 +405,7 @@ public class ChatBaseCell extends BaseCell implements MediaController.FileDownlo
isCheckPressed = true; isCheckPressed = true;
isAvatarVisible = false; isAvatarVisible = false;
wasLayout = false; wasLayout = false;
drawShareButton = false;
replyNameLayout = null; replyNameLayout = null;
replyTextLayout = null; replyTextLayout = null;
replyNameWidth = 0; replyNameWidth = 0;
@ -421,6 +428,9 @@ public class ChatBaseCell extends BaseCell implements MediaController.FileDownlo
currentUser = MessagesController.getInstance().getUser(messageObject.messageOwner.from_id); currentUser = MessagesController.getInstance().getUser(messageObject.messageOwner.from_id);
} else if (messageObject.messageOwner.from_id < 0) { } else if (messageObject.messageOwner.from_id < 0) {
currentChat = MessagesController.getInstance().getChat(-messageObject.messageOwner.from_id); currentChat = MessagesController.getInstance().getChat(-messageObject.messageOwner.from_id);
if (messageObject.messageOwner.to_id.channel_id != 0 && (messageObject.messageOwner.reply_to_msg_id == 0 || messageObject.type != 13)) {
drawShareButton = true;
}
} }
//if (isChat && !messageObject.isOutOwner() && messageObject.messageOwner.from_id > 0) { //if (isChat && !messageObject.isOutOwner() && messageObject.messageOwner.from_id > 0) {
if ( ((isChat || showAvatar) && !messageObject.isOutOwner() && messageObject.messageOwner.from_id > 0) if ( ((isChat || showAvatar) && !messageObject.isOutOwner() && messageObject.messageOwner.from_id > 0)
@ -457,7 +467,7 @@ public class ChatBaseCell extends BaseCell implements MediaController.FileDownlo
currentTimePaint = timeMediaPaint; currentTimePaint = timeMediaPaint;
} }
currentTimeString = LocaleController.formatterDay.format((long) (messageObject.messageOwner.date) * 1000); currentTimeString = LocaleController.getInstance().formatterDay.format((long) (messageObject.messageOwner.date) * 1000);
timeTextWidth = timeWidth = (int)Math.ceil(currentTimePaint.measureText(currentTimeString)); timeTextWidth = timeWidth = (int)Math.ceil(currentTimePaint.measureText(currentTimeString));
if ((messageObject.messageOwner.flags & TLRPC.MESSAGE_FLAG_HAS_VIEWS) != 0) { if ((messageObject.messageOwner.flags & TLRPC.MESSAGE_FLAG_HAS_VIEWS) != 0) {
currentViewsString = String.format("%s", LocaleController.formatShortNumber(Math.max(1, messageObject.messageOwner.views), null)); currentViewsString = String.format("%s", LocaleController.formatShortNumber(Math.max(1, messageObject.messageOwner.views), null));
@ -481,16 +491,23 @@ public class ChatBaseCell extends BaseCell implements MediaController.FileDownlo
currentNameString = "DELETED"; currentNameString = "DELETED";
} }
nameWidth = getMaxNameWidth(); nameWidth = getMaxNameWidth();
if (nameWidth < 0) {
nameWidth = AndroidUtilities.dp(100);
}
CharSequence nameStringFinal = TextUtils.ellipsize(currentNameString.replace("\n", " "), namePaint, nameWidth - AndroidUtilities.dp(12), TextUtils.TruncateAt.END); CharSequence nameStringFinal = TextUtils.ellipsize(currentNameString.replace("\n", " "), namePaint, nameWidth - AndroidUtilities.dp(12), TextUtils.TruncateAt.END);
try {
nameLayout = new StaticLayout(nameStringFinal, namePaint, nameWidth, Layout.Alignment.ALIGN_NORMAL, 1.0f, 0.0f, false); nameLayout = new StaticLayout(nameStringFinal, namePaint, nameWidth, Layout.Alignment.ALIGN_NORMAL, 1.0f, 0.0f, false);
if (nameLayout.getLineCount() > 0) { if (nameLayout != null && nameLayout.getLineCount() > 0) {
nameWidth = (int)Math.ceil(nameLayout.getLineWidth(0)); nameWidth = (int)Math.ceil(nameLayout.getLineWidth(0));
namesOffset += AndroidUtilities.dp(19); namesOffset += AndroidUtilities.dp(19);
nameOffsetX = nameLayout.getLineLeft(0); nameOffsetX = nameLayout.getLineLeft(0);
} else { } else {
nameWidth = 0; nameWidth = 0;
} }
} catch (Exception e) {
FileLog.e("tmessages", e);
}
} else { } else {
currentNameString = null; currentNameString = null;
nameLayout = null; nameLayout = null;
@ -665,16 +682,16 @@ public class ChatBaseCell extends BaseCell implements MediaController.FileDownlo
if (isAvatarVisible && avatarImage.isInsideImage(x, y)) { if (isAvatarVisible && avatarImage.isInsideImage(x, y)) {
avatarPressed = true; avatarPressed = true;
result = true; result = true;
} else if (drawForwardedName && forwardedNameLayout != null) { } else if (drawForwardedName && forwardedNameLayout != null && x >= forwardNameX && x <= forwardNameX + forwardedNameWidth && y >= forwardNameY && y <= forwardNameY + AndroidUtilities.dp(32)) {
if (x >= forwardNameX && x <= forwardNameX + forwardedNameWidth && y >= forwardNameY && y <= forwardNameY + AndroidUtilities.dp(32)) {
forwardNamePressed = true; forwardNamePressed = true;
result = true; result = true;
} } else if (currentMessageObject.isReply() && x >= replyStartX && x <= replyStartX + Math.max(replyNameWidth, replyTextWidth) && y >= replyStartY && y <= replyStartY + AndroidUtilities.dp(35)) {
} else if (currentMessageObject.isReply()) {
if (x >= replyStartX && x <= replyStartX + Math.max(replyNameWidth, replyTextWidth) && y >= replyStartY && y <= replyStartY + AndroidUtilities.dp(35)) {
replyPressed = true; replyPressed = true;
result = true; result = true;
} } else if (drawShareButton && x >= shareStartX && x <= shareStartX + AndroidUtilities.dp(40) && y >= shareStartY && y <= shareStartY + AndroidUtilities.dp(32)) {
sharePressed = true;
result = true;
invalidate();
} }
if (result) { if (result) {
startCheckLongPress(); startCheckLongPress();
@ -734,6 +751,21 @@ public class ChatBaseCell extends BaseCell implements MediaController.FileDownlo
replyPressed = false; replyPressed = false;
} }
} }
} else if (sharePressed) {
if (event.getAction() == MotionEvent.ACTION_UP) {
sharePressed = false;
playSoundEffect(SoundEffectConstants.CLICK);
if (delegate != null) {
delegate.didPressShare(this);
}
} else if (event.getAction() == MotionEvent.ACTION_CANCEL) {
sharePressed = false;
} else if (event.getAction() == MotionEvent.ACTION_MOVE) {
if (!(x >= shareStartX && x <= shareStartX + AndroidUtilities.dp(40) && y >= shareStartY && y <= shareStartY + AndroidUtilities.dp(32))) {
sharePressed = false;
}
}
invalidate();
} }
} }
return result; return result;
@ -868,6 +900,12 @@ public class ChatBaseCell extends BaseCell implements MediaController.FileDownlo
} }
onAfterBackgroundDraw(canvas); onAfterBackgroundDraw(canvas);
if (drawShareButton) {
ResourceLoader.shareDrawable[ApplicationLoader.isCustomTheme() ? 1 : 0][sharePressed ? 1 : 0].setBounds(shareStartX = currentBackgroundDrawable.getBounds().right + AndroidUtilities.dp(8), shareStartY = layoutHeight - AndroidUtilities.dp(41), currentBackgroundDrawable.getBounds().right + AndroidUtilities.dp(40), layoutHeight - AndroidUtilities.dp(9));
ResourceLoader.shareDrawable[ApplicationLoader.isCustomTheme() ? 1 : 0][sharePressed ? 1 : 0].draw(canvas);
}
SharedPreferences themePrefs = ApplicationLoader.applicationContext.getSharedPreferences(AndroidUtilities.THEME_PREFS, AndroidUtilities.THEME_PREFS_MODE); SharedPreferences themePrefs = ApplicationLoader.applicationContext.getSharedPreferences(AndroidUtilities.THEME_PREFS, AndroidUtilities.THEME_PREFS_MODE);
boolean mCheck = AndroidUtilities.getBoolPref("chatMemberColorCheck"); boolean mCheck = AndroidUtilities.getBoolPref("chatMemberColorCheck");
int mColor = themePrefs.getInt("chatMemberColor", AndroidUtilities.getIntDarkerColor("themeColor", 0x15)); int mColor = themePrefs.getInt("chatMemberColor", AndroidUtilities.getIntDarkerColor("themeColor", 0x15));

View File

@ -1,5 +1,5 @@
/* /*
* This is the source code of Telegram for Android v. 3.x.x * This is the source code of Telegram for Android v. 3.x.x.
* It is licensed under GNU GPL v. 2 or later. * It is licensed under GNU GPL v. 2 or later.
* You should have received a copy of the license in this archive (see LICENSE). * You should have received a copy of the license in this archive (see LICENSE).
* *
@ -210,6 +210,9 @@ public class ChatContactCell extends ChatBaseCell {
String currentNameString = ContactsController.formatName(messageObject.messageOwner.media.first_name, messageObject.messageOwner.media.last_name); String currentNameString = ContactsController.formatName(messageObject.messageOwner.media.first_name, messageObject.messageOwner.media.last_name);
int nameWidth = Math.min((int) Math.ceil(namePaint.measureText(currentNameString)), maxWidth); int nameWidth = Math.min((int) Math.ceil(namePaint.measureText(currentNameString)), maxWidth);
if (maxWidth < 0) {
maxWidth = AndroidUtilities.dp(100);
}
CharSequence stringFinal = TextUtils.ellipsize(currentNameString.replace("\n", " "), namePaint, nameWidth, TextUtils.TruncateAt.END); CharSequence stringFinal = TextUtils.ellipsize(currentNameString.replace("\n", " "), namePaint, nameWidth, TextUtils.TruncateAt.END);
nameLayout = new StaticLayout(stringFinal, namePaint, nameWidth, Layout.Alignment.ALIGN_NORMAL, 1.0f, 0.0f, false); nameLayout = new StaticLayout(stringFinal, namePaint, nameWidth, Layout.Alignment.ALIGN_NORMAL, 1.0f, 0.0f, false);

View File

@ -1,5 +1,5 @@
/* /*
* This is the source code of Telegram for Android v. 3.x.x * This is the source code of Telegram for Android v. 3.x.x.
* It is licensed under GNU GPL v. 2 or later. * It is licensed under GNU GPL v. 2 or later.
* You should have received a copy of the license in this archive (see LICENSE). * You should have received a copy of the license in this archive (see LICENSE).
* *
@ -540,7 +540,7 @@ public class ChatMediaCell extends ChatBaseCell {
currentNameString = name; currentNameString = name;
maxWidth = maxWidth + AndroidUtilities.dp(1); //to fix 2 lines bug maxWidth = maxWidth + AndroidUtilities.dp(1); //to fix 2 lines bug
nameLayout = StaticLayoutEx.createStaticLayout(currentNameString, namePaint, maxWidth, Layout.Alignment.ALIGN_NORMAL, 1.0f, 0.0f, false, TextUtils.TruncateAt.END, maxWidth, 1); nameLayout = StaticLayoutEx.createStaticLayout(currentNameString, namePaint, maxWidth, Layout.Alignment.ALIGN_NORMAL, 1.0f, 0.0f, false, TextUtils.TruncateAt.END, maxWidth, 1);
if (nameLayout.getLineCount() > 0) { if (nameLayout != null && nameLayout.getLineCount() > 0) {
nameWidth = Math.min(maxWidth, (int) Math.ceil(nameLayout.getLineWidth(0))); nameWidth = Math.min(maxWidth, (int) Math.ceil(nameLayout.getLineWidth(0)));
nameOffsetX = (int) Math.ceil(-nameLayout.getLineLeft(0)); nameOffsetX = (int) Math.ceil(-nameLayout.getLineLeft(0));
} else { } else {
@ -555,7 +555,6 @@ public class ChatMediaCell extends ChatBaseCell {
if (currentInfoString == null || !currentInfoString.equals(str)) { if (currentInfoString == null || !currentInfoString.equals(str)) {
currentInfoString = str; currentInfoString = str;
infoOffset = 0; infoOffset = 0;
infoWidth = Math.min(maxWidth, (int) Math.ceil(infoPaint.measureText(currentInfoString))); infoWidth = Math.min(maxWidth, (int) Math.ceil(infoPaint.measureText(currentInfoString)));
infoLayout2 = null; infoLayout2 = null;
@ -843,13 +842,14 @@ public class ChatMediaCell extends ChatBaseCell {
backgroundWidth += AndroidUtilities.dp(9); backgroundWidth += AndroidUtilities.dp(9);
} }
if (messageObject.caption != null) { if (messageObject.caption != null) {
try {
if(messageObject.isOutOwner()){ //fix caption color bug if(messageObject.isOutOwner()){ //fix caption color bug
MessageObject.textPaint = MessageObject.textPaintRight; MessageObject.textPaint = MessageObject.textPaintRight;
}else{ }else{
MessageObject.textPaint = MessageObject.textPaintLeft; MessageObject.textPaint = MessageObject.textPaintLeft;
} }
nameLayout = new StaticLayout(messageObject.caption, MessageObject.textPaint, photoWidth - AndroidUtilities.dp(10), Layout.Alignment.ALIGN_NORMAL, 1.0f, 0.0f, false); nameLayout = new StaticLayout(messageObject.caption, MessageObject.textPaint, photoWidth - AndroidUtilities.dp(10), Layout.Alignment.ALIGN_NORMAL, 1.0f, 0.0f, false);
if (nameLayout.getLineCount() > 0) { if (nameLayout != null && nameLayout.getLineCount() > 0) {
captionHeight = nameLayout.getHeight(); captionHeight = nameLayout.getHeight();
additionHeight += captionHeight + AndroidUtilities.dp(9); additionHeight += captionHeight + AndroidUtilities.dp(9);
float lastLineWidth = nameLayout.getLineWidth(nameLayout.getLineCount() - 1) + nameLayout.getLineLeft(nameLayout.getLineCount() - 1); float lastLineWidth = nameLayout.getLineWidth(nameLayout.getLineCount() - 1) + nameLayout.getLineLeft(nameLayout.getLineCount() - 1);
@ -857,6 +857,9 @@ public class ChatMediaCell extends ChatBaseCell {
additionHeight += AndroidUtilities.dp(14); additionHeight += AndroidUtilities.dp(14);
} }
} }
} catch (Exception e) {
FileLog.e("tmessages", e);
}
} }
currentPhotoFilter = String.format(Locale.US, "%d_%d", (int) (w / AndroidUtilities.density), (int) (h / AndroidUtilities.density)); currentPhotoFilter = String.format(Locale.US, "%d_%d", (int) (w / AndroidUtilities.density), (int) (h / AndroidUtilities.density));

View File

@ -543,17 +543,18 @@ public class ChatMessageCell extends ChatBaseCell {
} }
} }
boolean authorIsRTL = false;
if (webPage.author != null) { if (webPage.author != null) {
try { try {
if (linkPreviewHeight != 0) { if (linkPreviewHeight != 0) {
linkPreviewHeight += AndroidUtilities.dp(2); linkPreviewHeight += AndroidUtilities.dp(2);
totalHeight += AndroidUtilities.dp(2); totalHeight += AndroidUtilities.dp(2);
} }
int width = Math.min((int) Math.ceil(replyNamePaint.measureText(webPage.author)), linkPreviewMaxWidth); //int width = Math.min((int) Math.ceil(replyNamePaint.measureText(webPage.author)), linkPreviewMaxWidth);
if (restLinesCount == 3 && (!isSmallImage || webPage.description == null)) { if (restLinesCount == 3 && (!isSmallImage || webPage.description == null)) {
authorLayout = new StaticLayout(webPage.author, replyNamePaint, width, Layout.Alignment.ALIGN_NORMAL, 1.0f, 0.0f, false); authorLayout = new StaticLayout(webPage.author, replyNamePaint, linkPreviewMaxWidth, Layout.Alignment.ALIGN_NORMAL, 1.0f, 0.0f, false);
} else { } else {
authorLayout = generateStaticLayout(webPage.author, replyNamePaint, width, linkPreviewMaxWidth - AndroidUtilities.dp(48 + 2), restLinesCount, 1); authorLayout = generateStaticLayout(webPage.author, replyNamePaint, linkPreviewMaxWidth, linkPreviewMaxWidth - AndroidUtilities.dp(48 + 2), restLinesCount, 1);
restLinesCount -= authorLayout.getLineCount(); restLinesCount -= authorLayout.getLineCount();
} }
int height = authorLayout.getLineBottom(authorLayout.getLineCount() - 1); int height = authorLayout.getLineBottom(authorLayout.getLineCount() - 1);
@ -561,6 +562,13 @@ public class ChatMessageCell extends ChatBaseCell {
totalHeight += height; totalHeight += height;
int lineLeft = (int) authorLayout.getLineLeft(0); int lineLeft = (int) authorLayout.getLineLeft(0);
authorX = -lineLeft; authorX = -lineLeft;
int width;
if (lineLeft != 0) {
width = authorLayout.getWidth() - lineLeft;
authorIsRTL = true;
} else {
width = (int) Math.ceil(authorLayout.getLineWidth(0));
}
maxChildWidth = Math.max(maxChildWidth, width + additinalWidth); maxChildWidth = Math.max(maxChildWidth, width + additinalWidth);
maxWebWidth = Math.max(maxWebWidth, width + additinalWidth); maxWebWidth = Math.max(maxWebWidth, width + additinalWidth);
} catch (Exception e) { } catch (Exception e) {
@ -586,19 +594,31 @@ public class ChatMessageCell extends ChatBaseCell {
int height = descriptionLayout.getLineBottom(descriptionLayout.getLineCount() - 1); int height = descriptionLayout.getLineBottom(descriptionLayout.getLineCount() - 1);
linkPreviewHeight += height; linkPreviewHeight += height;
totalHeight += height; totalHeight += height;
boolean hasRTL = false;
for (int a = 0; a < descriptionLayout.getLineCount(); a++) { for (int a = 0; a < descriptionLayout.getLineCount(); a++) {
int lineLeft = (int) Math.ceil(descriptionLayout.getLineLeft(a)); int lineLeft = (int) Math.ceil(descriptionLayout.getLineLeft(a));
if (a == 0 && descriptionX == 0) { if (lineLeft != 0) {
hasRTL = true;
if (descriptionX == 0) {
descriptionX = -lineLeft; descriptionX = -lineLeft;
} else { } else {
descriptionX = Math.max(descriptionX, -lineLeft); descriptionX = Math.max(descriptionX, -lineLeft);
} }
}
}
for (int a = 0; a < descriptionLayout.getLineCount(); a++) {
int lineLeft = (int) Math.ceil(descriptionLayout.getLineLeft(a));
if (lineLeft == 0 && descriptionX != 0) {
descriptionX = 0;
}
int width; int width;
if (lineLeft != 0) { if (lineLeft != 0) {
width = descriptionLayout.getWidth() - lineLeft; width = descriptionLayout.getWidth() - lineLeft;
} else { } else {
width = (int) Math.ceil(descriptionLayout.getLineWidth(a)); width = hasRTL ? descriptionLayout.getWidth() : (int) Math.ceil(descriptionLayout.getLineWidth(a));
} }
if (a < restLines || lineLeft != 0 && isSmallImage) { if (a < restLines || lineLeft != 0 && isSmallImage) {
width += AndroidUtilities.dp(48 + 2); width += AndroidUtilities.dp(48 + 2);
@ -607,6 +627,9 @@ public class ChatMessageCell extends ChatBaseCell {
if (titleIsRTL) { if (titleIsRTL) {
titleX += (width + additinalWidth - maxWebWidth); titleX += (width + additinalWidth - maxWebWidth);
} }
if (authorIsRTL) {
authorX += (width + additinalWidth - maxWebWidth);
}
maxWebWidth = width + additinalWidth; maxWebWidth = width + additinalWidth;
} }
maxChildWidth = Math.max(maxChildWidth, width + additinalWidth); maxChildWidth = Math.max(maxChildWidth, width + additinalWidth);

View File

@ -24,6 +24,7 @@ import android.view.MotionEvent;
import org.telegram.PhoneFormat.PhoneFormat; import org.telegram.PhoneFormat.PhoneFormat;
import org.telegram.messenger.AndroidUtilities; import org.telegram.messenger.AndroidUtilities;
import org.telegram.messenger.ApplicationLoader; import org.telegram.messenger.ApplicationLoader;
import org.telegram.messenger.ChatObject;
import org.telegram.messenger.ContactsController; import org.telegram.messenger.ContactsController;
import org.telegram.messenger.Emoji; import org.telegram.messenger.Emoji;
import org.telegram.messenger.FileLog; import org.telegram.messenger.FileLog;
@ -62,6 +63,7 @@ public class DialogCell extends BaseCell {
private static Drawable countDrawableGrey; private static Drawable countDrawableGrey;
private static Drawable groupDrawable; private static Drawable groupDrawable;
private static Drawable broadcastDrawable; private static Drawable broadcastDrawable;
private static Drawable botDrawable;
private static Drawable muteDrawable; private static Drawable muteDrawable;
private static Drawable verifiedDrawable; private static Drawable verifiedDrawable;
@ -94,6 +96,7 @@ public class DialogCell extends BaseCell {
private boolean drawNameLock; private boolean drawNameLock;
private boolean drawNameGroup; private boolean drawNameGroup;
private boolean drawNameBroadcast; private boolean drawNameBroadcast;
private boolean drawNameBot;
private int nameMuteLeft; private int nameMuteLeft;
private int nameLockLeft; private int nameLockLeft;
private int nameLockTop; private int nameLockTop;
@ -200,6 +203,7 @@ public class DialogCell extends BaseCell {
broadcastDrawable = getResources().getDrawable(R.drawable.list_broadcast); broadcastDrawable = getResources().getDrawable(R.drawable.list_broadcast);
muteDrawable = getResources().getDrawable(R.drawable.mute_grey); muteDrawable = getResources().getDrawable(R.drawable.mute_grey);
verifiedDrawable = getResources().getDrawable(R.drawable.check_list); verifiedDrawable = getResources().getDrawable(R.drawable.check_list);
botDrawable = getResources().getDrawable(R.drawable.bot_list);
} }
setBackgroundResource(R.drawable.list_selector); setBackgroundResource(R.drawable.list_selector);
@ -288,6 +292,7 @@ public class DialogCell extends BaseCell {
drawNameGroup = false; drawNameGroup = false;
drawNameBroadcast = false; drawNameBroadcast = false;
drawNameLock = false; drawNameLock = false;
drawNameBot = false;
drawVerified = false; drawVerified = false;
if (encryptedChat != null) { if (encryptedChat != null) {
@ -302,14 +307,14 @@ public class DialogCell extends BaseCell {
} }
} else { } else {
if (chat != null) { if (chat != null) {
if (chat.id < 0 || chat instanceof TLRPC.TL_channel || chat instanceof TLRPC.TL_channelForbidden) { if (chat.id < 0 || ChatObject.isChannel(chat) && !chat.megagroup) {
drawNameBroadcast = true; drawNameBroadcast = true;
nameLockTop = AndroidUtilities.dp(16.5f); nameLockTop = AndroidUtilities.dp(16.5f);
} else { } else {
drawNameGroup = true; drawNameGroup = true;
nameLockTop = AndroidUtilities.dp(17.5f); nameLockTop = AndroidUtilities.dp(17.5f);
} }
drawVerified = (chat.flags & TLRPC.CHAT_FLAG_IS_VERIFIED) != 0; drawVerified = chat.verified;
if (!LocaleController.isRTL) { if (!LocaleController.isRTL) {
nameLockLeft = AndroidUtilities.dp(AndroidUtilities.leftBaseline); nameLockLeft = AndroidUtilities.dp(AndroidUtilities.leftBaseline);
@ -324,6 +329,20 @@ public class DialogCell extends BaseCell {
} else { } else {
nameLeft = AndroidUtilities.dp(14); nameLeft = AndroidUtilities.dp(14);
} }
if (user != null) {
if (user.bot) {
drawNameBot = true;
nameLockTop = AndroidUtilities.dp(16.5f);
if (!LocaleController.isRTL) {
nameLockLeft = AndroidUtilities.dp(AndroidUtilities.leftBaseline);
nameLeft = AndroidUtilities.dp(AndroidUtilities.leftBaseline + 4) + botDrawable.getIntrinsicWidth();
} else {
nameLockLeft = getMeasuredWidth() - AndroidUtilities.dp(AndroidUtilities.leftBaseline) - botDrawable.getIntrinsicWidth();
nameLeft = AndroidUtilities.dp(14);
}
}
drawVerified = user.verified;
}
} }
} }
@ -534,6 +553,8 @@ public class DialogCell extends BaseCell {
nameWidth -= AndroidUtilities.dp(4) + groupDrawable.getIntrinsicWidth(); nameWidth -= AndroidUtilities.dp(4) + groupDrawable.getIntrinsicWidth();
} else if (drawNameBroadcast) { } else if (drawNameBroadcast) {
nameWidth -= AndroidUtilities.dp(4) + broadcastDrawable.getIntrinsicWidth(); nameWidth -= AndroidUtilities.dp(4) + broadcastDrawable.getIntrinsicWidth();
} else if (drawNameBot) {
nameWidth -= AndroidUtilities.dp(4) + botDrawable.getIntrinsicWidth();
} }
if (drawClock) { if (drawClock) {
int w = clockDrawable.getIntrinsicWidth() + AndroidUtilities.dp(5); int w = clockDrawable.getIntrinsicWidth() + AndroidUtilities.dp(5);
@ -719,7 +740,7 @@ public class DialogCell extends BaseCell {
public void checkCurrentDialogIndex() { public void checkCurrentDialogIndex() {
if (index < getDialogsArray().size()) { if (index < getDialogsArray().size()) {
TLRPC.Dialog dialog = getDialogsArray().get(index); TLRPC.Dialog dialog = getDialogsArray().get(index);
if (currentDialogId != dialog.id || message != null && message.getId() != dialog.top_message || unreadCount != dialog.unread_count) { if (currentDialogId != dialog.id || message != null && message.getId() != dialog.top_message || unreadCount != dialog.unread_count || message == null && MessagesController.getInstance().dialogMessage.get(dialog.id) != null) {
currentDialogId = dialog.id; currentDialogId = dialog.id;
update(0); update(0);
} }
@ -808,6 +829,12 @@ public class DialogCell extends BaseCell {
} else { } else {
if (lower_id < 0) { if (lower_id < 0) {
chat = MessagesController.getInstance().getChat(-lower_id); chat = MessagesController.getInstance().getChat(-lower_id);
if (!isDialogCell && chat != null && chat.migrated_to != null) {
TLRPC.Chat chat2 = MessagesController.getInstance().getChat(chat.migrated_to.channel_id);
if (chat2 != null) {
chat = chat2;
}
}
} else { } else {
user = MessagesController.getInstance().getUser(lower_id); user = MessagesController.getInstance().getUser(lower_id);
} }
@ -890,6 +917,7 @@ public class DialogCell extends BaseCell {
nColor = themePrefs.getInt("chatsGroupIconColor", themePrefs.getInt("chatsGroupNameColor", 0xff000000)); nColor = themePrefs.getInt("chatsGroupIconColor", themePrefs.getInt("chatsGroupNameColor", 0xff000000));
groupDrawable.setColorFilter(nColor, PorterDuff.Mode.SRC_IN); groupDrawable.setColorFilter(nColor, PorterDuff.Mode.SRC_IN);
broadcastDrawable.setColorFilter(nColor, PorterDuff.Mode.SRC_IN); broadcastDrawable.setColorFilter(nColor, PorterDuff.Mode.SRC_IN);
botDrawable.setColorFilter(nColor, PorterDuff.Mode.SRC_IN);
int mColor = themePrefs.getInt("chatsMuteColor", 0xffa8a8a8); int mColor = themePrefs.getInt("chatsMuteColor", 0xffa8a8a8);
//muteWhiteDrawable.setColorFilter(mColor, PorterDuff.Mode.MULTIPLY); //muteWhiteDrawable.setColorFilter(mColor, PorterDuff.Mode.MULTIPLY);
@ -924,6 +952,9 @@ public class DialogCell extends BaseCell {
} else if (drawNameBroadcast) { } else if (drawNameBroadcast) {
setDrawableBounds(broadcastDrawable, nameLockLeft, nameLockTop); setDrawableBounds(broadcastDrawable, nameLockLeft, nameLockTop);
broadcastDrawable.draw(canvas); broadcastDrawable.draw(canvas);
} else if (drawNameBot) {
setDrawableBounds(botDrawable, nameLockLeft, nameLockTop);
botDrawable.draw(canvas);
} }
if (nameLayout != null) { if (nameLayout != null) {

View File

@ -1,5 +1,5 @@
/* /*
* This is the source code of Telegram for Android v. 3.x.x * This is the source code of Telegram for Android v. 3.x.x.
* It is licensed under GNU GPL v. 2 or later. * It is licensed under GNU GPL v. 2 or later.
* You should have received a copy of the license in this archive (see LICENSE). * You should have received a copy of the license in this archive (see LICENSE).
* *

View File

@ -1,5 +1,5 @@
/* /*
* This is the source code of Telegram for Android v. 3.x.x * This is the source code of Telegram for Android v. 3.x.x.
* It is licensed under GNU GPL v. 2 or later. * It is licensed under GNU GPL v. 2 or later.
* You should have received a copy of the license in this archive (see LICENSE). * You should have received a copy of the license in this archive (see LICENSE).
* *
@ -46,15 +46,14 @@ public class DrawerActionCell extends FrameLayout {
} }
public void setTextAndIcon(String text, int resId) { public void setTextAndIcon(String text, int resId) {
textView.setText(text); try {
//textView.setCompoundDrawablesWithIntrinsicBounds(resId, 0, 0, 0); textView.setText(text);
int color = AndroidUtilities.getIntDef("drawerIconColor", 0xff737373); //textView.setCompoundDrawablesWithIntrinsicBounds(resId, 0, 0, 0);
try{ int color = AndroidUtilities.getIntDef("drawerIconColor", 0xff737373);
Drawable d = getResources().getDrawable(resId); Drawable d = getResources().getDrawable(resId);
d.setColorFilter(color, PorterDuff.Mode.SRC_IN); d.setColorFilter(color, PorterDuff.Mode.SRC_IN);
textView.setCompoundDrawablesWithIntrinsicBounds(d, null, null, null); textView.setCompoundDrawablesWithIntrinsicBounds(d, null, null, null);
} catch (Exception e) { } catch (Throwable e) {
textView.setCompoundDrawablesWithIntrinsicBounds(resId, 0, 0, 0);
FileLog.e("tmessages", e); FileLog.e("tmessages", e);
} }
} }

View File

@ -1,5 +1,5 @@
/* /*
* This is the source code of Telegram for Android v. 3.x.x * This is the source code of Telegram for Android v. 3.x.x.
* It is licensed under GNU GPL v. 2 or later. * It is licensed under GNU GPL v. 2 or later.
* You should have received a copy of the license in this archive (see LICENSE). * You should have received a copy of the license in this archive (see LICENSE).
* *

View File

@ -1,5 +1,5 @@
/* /*
* This is the source code of Telegram for Android v. 3.x.x * This is the source code of Telegram for Android v. 3.x.x.
* It is licensed under GNU GPL v. 2 or later. * It is licensed under GNU GPL v. 2 or later.
* You should have received a copy of the license in this archive (see LICENSE). * You should have received a copy of the license in this archive (see LICENSE).
* *

View File

@ -1,5 +1,5 @@
/* /*
* This is the source code of Telegram for Android v. 3.x.x * This is the source code of Telegram for Android v. 3.x.x.
* It is licensed under GNU GPL v. 2 or later. * It is licensed under GNU GPL v. 2 or later.
* You should have received a copy of the license in this archive (see LICENSE). * You should have received a copy of the license in this archive (see LICENSE).
* *

View File

@ -44,9 +44,11 @@ public class ProfileSearchCell extends BaseCell {
private static TextPaint offlinePaint; private static TextPaint offlinePaint;
private static TextPaint countPaint; private static TextPaint countPaint;
private static Drawable lockDrawable; private static Drawable lockDrawable;
private static Drawable botDrawable;
private static Drawable broadcastDrawable; private static Drawable broadcastDrawable;
private static Drawable groupDrawable; private static Drawable groupDrawable;
private static Drawable countDrawable; private static Drawable countDrawable;
private static Drawable countDrawableGrey;
private static Drawable checkDrawable; private static Drawable checkDrawable;
private static Paint linePaint; private static Paint linePaint;
@ -58,7 +60,7 @@ public class ProfileSearchCell extends BaseCell {
private TLRPC.User user = null; private TLRPC.User user = null;
private TLRPC.Chat chat = null; private TLRPC.Chat chat = null;
private TLRPC.EncryptedChat encryptedChat = null; private TLRPC.EncryptedChat encryptedChat = null;
long dialog_id; private long dialog_id;
private String lastName = null; private String lastName = null;
private int lastStatus = 0; private int lastStatus = 0;
@ -73,6 +75,7 @@ public class ProfileSearchCell extends BaseCell {
private boolean drawNameLock; private boolean drawNameLock;
private boolean drawNameBroadcast; private boolean drawNameBroadcast;
private boolean drawNameGroup; private boolean drawNameGroup;
private boolean drawNameBot;
private int nameLockLeft; private int nameLockLeft;
private int nameLockTop; private int nameLockTop;
@ -124,7 +127,9 @@ public class ProfileSearchCell extends BaseCell {
lockDrawable = getResources().getDrawable(R.drawable.list_secret); lockDrawable = getResources().getDrawable(R.drawable.list_secret);
groupDrawable = getResources().getDrawable(R.drawable.list_group); groupDrawable = getResources().getDrawable(R.drawable.list_group);
countDrawable = getResources().getDrawable(R.drawable.dialogs_badge); countDrawable = getResources().getDrawable(R.drawable.dialogs_badge);
countDrawableGrey = getResources().getDrawable(R.drawable.dialogs_badge2);
checkDrawable = getResources().getDrawable(R.drawable.check_list); checkDrawable = getResources().getDrawable(R.drawable.check_list);
botDrawable = getResources().getDrawable(R.drawable.bot_list);
updateTheme(); updateTheme();
} }
@ -202,6 +207,7 @@ public class ProfileSearchCell extends BaseCell {
drawNameLock = false; drawNameLock = false;
drawNameGroup = false; drawNameGroup = false;
drawCheck = false; drawCheck = false;
drawNameBot = false;
if (encryptedChat != null) { if (encryptedChat != null) {
drawNameLock = true; drawNameLock = true;
@ -222,7 +228,7 @@ public class ProfileSearchCell extends BaseCell {
nameLockTop = AndroidUtilities.dp(28.5f); nameLockTop = AndroidUtilities.dp(28.5f);
} else { } else {
dialog_id = -chat.id; dialog_id = -chat.id;
if (ChatObject.isChannel(chat)) { if (ChatObject.isChannel(chat) && !chat.megagroup) {
drawNameBroadcast = true; drawNameBroadcast = true;
nameLockTop = AndroidUtilities.dp(28.5f); nameLockTop = AndroidUtilities.dp(28.5f);
} else { } else {
@ -230,7 +236,7 @@ public class ProfileSearchCell extends BaseCell {
nameLockTop = AndroidUtilities.dp(30); nameLockTop = AndroidUtilities.dp(30);
} }
} }
drawCheck = (chat.flags & TLRPC.CHAT_FLAG_IS_VERIFIED) != 0; drawCheck = chat.verified;
if (!LocaleController.isRTL) { if (!LocaleController.isRTL) {
nameLockLeft = AndroidUtilities.dp(AndroidUtilities.leftBaseline); nameLockLeft = AndroidUtilities.dp(AndroidUtilities.leftBaseline);
nameLeft = AndroidUtilities.dp(AndroidUtilities.leftBaseline + 4) + (drawNameGroup ? groupDrawable.getIntrinsicWidth() : broadcastDrawable.getIntrinsicWidth()); nameLeft = AndroidUtilities.dp(AndroidUtilities.leftBaseline + 4) + (drawNameGroup ? groupDrawable.getIntrinsicWidth() : broadcastDrawable.getIntrinsicWidth());
@ -245,6 +251,20 @@ public class ProfileSearchCell extends BaseCell {
} else { } else {
nameLeft = AndroidUtilities.dp(11); nameLeft = AndroidUtilities.dp(11);
} }
if (user.bot) {
drawNameBot = true;
if (!LocaleController.isRTL) {
nameLockLeft = AndroidUtilities.dp(AndroidUtilities.leftBaseline);
nameLeft = AndroidUtilities.dp(AndroidUtilities.leftBaseline + 4) + botDrawable.getIntrinsicWidth();
} else {
nameLockLeft = getMeasuredWidth() - AndroidUtilities.dp(AndroidUtilities.leftBaseline + 2) - botDrawable.getIntrinsicWidth();
nameLeft = AndroidUtilities.dp(11);
}
nameLockTop = AndroidUtilities.dp(16.5f);
} else {
nameLockTop = AndroidUtilities.dp(17);
}
drawCheck = user.verified;
} }
} }
@ -285,6 +305,8 @@ public class ProfileSearchCell extends BaseCell {
nameWidth -= AndroidUtilities.dp(6) + broadcastDrawable.getIntrinsicWidth(); nameWidth -= AndroidUtilities.dp(6) + broadcastDrawable.getIntrinsicWidth();
} else if (drawNameGroup) { } else if (drawNameGroup) {
nameWidth -= AndroidUtilities.dp(6) + groupDrawable.getIntrinsicWidth(); nameWidth -= AndroidUtilities.dp(6) + groupDrawable.getIntrinsicWidth();
} else if (drawNameBot) {
nameWidth -= AndroidUtilities.dp(6) + botDrawable.getIntrinsicWidth();
} }
if (drawCount) { if (drawCount) {
@ -327,7 +349,7 @@ public class ProfileSearchCell extends BaseCell {
if (subLabel != null) { if (subLabel != null) {
onlineString = subLabel; onlineString = subLabel;
} else if (user != null) { } else if (user != null) {
if ((user.flags & TLRPC.USER_FLAG_BOT) != 0) { if (user.bot) {
onlineString = LocaleController.getString("Bot", R.string.Bot); onlineString = LocaleController.getString("Bot", R.string.Bot);
} else { } else {
onlineString = LocaleController.formatUserStatus(user); onlineString = LocaleController.formatUserStatus(user);
@ -341,7 +363,7 @@ public class ProfileSearchCell extends BaseCell {
CharSequence onlineStringFinal = TextUtils.ellipsize(onlineString, currentOnlinePaint, onlineWidth - AndroidUtilities.dp(12), TextUtils.TruncateAt.END); CharSequence onlineStringFinal = TextUtils.ellipsize(onlineString, currentOnlinePaint, onlineWidth - AndroidUtilities.dp(12), TextUtils.TruncateAt.END);
onlineLayout = new StaticLayout(onlineStringFinal, currentOnlinePaint, onlineWidth, Layout.Alignment.ALIGN_NORMAL, 1.0f, 0.0f, false); onlineLayout = new StaticLayout(onlineStringFinal, currentOnlinePaint, onlineWidth, Layout.Alignment.ALIGN_NORMAL, 1.0f, 0.0f, false);
nameTop = AndroidUtilities.dp(13); nameTop = AndroidUtilities.dp(13);
if (subLabel != null) { if (subLabel != null && !drawNameBot) {
nameLockTop -= AndroidUtilities.dp(12); nameLockTop -= AndroidUtilities.dp(12);
} }
} else { } else {
@ -506,6 +528,9 @@ public class ProfileSearchCell extends BaseCell {
} else if (drawNameBroadcast) { } else if (drawNameBroadcast) {
setDrawableBounds(broadcastDrawable, nameLockLeft, nameLockTop); setDrawableBounds(broadcastDrawable, nameLockLeft, nameLockTop);
broadcastDrawable.draw(canvas); broadcastDrawable.draw(canvas);
} else if (drawNameBot) {
setDrawableBounds(botDrawable, nameLockLeft, nameLockTop);
botDrawable.draw(canvas);
} }
if (nameLayout != null) { if (nameLayout != null) {
@ -531,8 +556,13 @@ public class ProfileSearchCell extends BaseCell {
} }
if (countLayout != null) { if (countLayout != null) {
if (MessagesController.getInstance().isDialogMuted(dialog_id)) {
setDrawableBounds(countDrawableGrey, countLeft - AndroidUtilities.dp(5.5f), countTop, countWidth + AndroidUtilities.dp(11), countDrawableGrey.getIntrinsicHeight());
countDrawableGrey.draw(canvas);
} else {
setDrawableBounds(countDrawable, countLeft - AndroidUtilities.dp(5.5f), countTop, countWidth + AndroidUtilities.dp(11), countDrawable.getIntrinsicHeight()); setDrawableBounds(countDrawable, countLeft - AndroidUtilities.dp(5.5f), countTop, countWidth + AndroidUtilities.dp(11), countDrawable.getIntrinsicHeight());
countDrawable.draw(canvas); countDrawable.draw(canvas);
}
canvas.save(); canvas.save();
canvas.translate(countLeft, countTop + AndroidUtilities.dp(4)); canvas.translate(countLeft, countTop + AndroidUtilities.dp(4));
countLayout.draw(canvas); countLayout.draw(canvas);

View File

@ -220,7 +220,7 @@ public class SharedDocumentCell extends FrameLayout implements MediaController.F
thumbImageView.setImage(document.messageOwner.media.document.thumb.location, "40_40", (Drawable) null); thumbImageView.setImage(document.messageOwner.media.document.thumb.location, "40_40", (Drawable) null);
} }
long date = (long) document.messageOwner.date * 1000; long date = (long) document.messageOwner.date * 1000;
dateTextView.setText(String.format("%s, %s", AndroidUtilities.formatFileSize(document.messageOwner.media.document.size), LocaleController.formatString("formatDateAtTime", R.string.formatDateAtTime, LocaleController.formatterYear.format(new Date(date)), LocaleController.formatterDay.format(new Date(date))))); dateTextView.setText(String.format("%s, %s", AndroidUtilities.formatFileSize(document.messageOwner.media.document.size), LocaleController.formatString("formatDateAtTime", R.string.formatDateAtTime, LocaleController.getInstance().formatterYear.format(new Date(date)), LocaleController.getInstance().formatterDay.format(new Date(date)))));
} else { } else {
nameTextView.setText(""); nameTextView.setText("");
extTextView.setText(""); extTextView.setText("");

View File

@ -28,8 +28,6 @@ public class TextCell extends FrameLayout {
private ImageView imageView; private ImageView imageView;
private ImageView valueImageView; private ImageView valueImageView;
private boolean multiline;
public TextCell(Context context) { public TextCell(Context context) {
super(context); super(context);
@ -64,7 +62,7 @@ public class TextCell extends FrameLayout {
@Override @Override
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
super.onMeasure(MeasureSpec.makeMeasureSpec(MeasureSpec.getSize(widthMeasureSpec), MeasureSpec.EXACTLY), multiline ? MeasureSpec.makeMeasureSpec(0, MeasureSpec.UNSPECIFIED) : MeasureSpec.makeMeasureSpec(AndroidUtilities.dp(48), MeasureSpec.EXACTLY)); super.onMeasure(MeasureSpec.makeMeasureSpec(MeasureSpec.getSize(widthMeasureSpec), MeasureSpec.EXACTLY), MeasureSpec.makeMeasureSpec(AndroidUtilities.dp(48), MeasureSpec.EXACTLY));
} }
public void setTextColor(int color) { public void setTextColor(int color) {
@ -84,27 +82,7 @@ public class TextCell extends FrameLayout {
imageView.setVisibility(VISIBLE); imageView.setVisibility(VISIBLE);
valueTextView.setVisibility(INVISIBLE); valueTextView.setVisibility(INVISIBLE);
valueImageView.setVisibility(INVISIBLE); valueImageView.setVisibility(INVISIBLE);
if (multiline) { imageView.setPadding(0, AndroidUtilities.dp(7), 0, 0);
imageView.setPadding(0, 0, 0, 0);
} else {
imageView.setPadding(0, AndroidUtilities.dp(7), 0, 0);
}
}
public void setMultiline(boolean value) {
if (multiline == value) {
return;
}
multiline = value;
if (value) {
textView.setSingleLine(false);
textView.setPadding(0, AndroidUtilities.dp(6), 0, AndroidUtilities.dp(6));
} else {
textView.setLines(1);
textView.setMaxLines(1);
textView.setSingleLine(true);
}
requestLayout();
} }
public void setTextSize(int size) { public void setTextSize(int size) {
@ -137,10 +115,6 @@ public class TextCell extends FrameLayout {
valueImageView.setImageDrawable(drawable); valueImageView.setImageDrawable(drawable);
valueTextView.setVisibility(INVISIBLE); valueTextView.setVisibility(INVISIBLE);
imageView.setVisibility(INVISIBLE); imageView.setVisibility(INVISIBLE);
if (multiline) { imageView.setPadding(0, AndroidUtilities.dp(7), 0, 0);
imageView.setPadding(0, 0, 0, 0);
} else {
imageView.setPadding(0, AndroidUtilities.dp(7), 0, 0);
}
} }
} }

View File

@ -29,6 +29,7 @@ import org.telegram.tgnet.TLRPC;
import org.telegram.ui.Components.AvatarDrawable; import org.telegram.ui.Components.AvatarDrawable;
import org.telegram.ui.Components.BackupImageView; import org.telegram.ui.Components.BackupImageView;
import org.telegram.ui.Components.CheckBox; import org.telegram.ui.Components.CheckBox;
import org.telegram.ui.Components.CheckBoxSquare;
import org.telegram.ui.Components.LayoutHelper; import org.telegram.ui.Components.LayoutHelper;
import org.telegram.ui.Components.SimpleTextView; import org.telegram.ui.Components.SimpleTextView;
@ -39,6 +40,7 @@ public class UserCell extends FrameLayout {
private SimpleTextView statusTextView; private SimpleTextView statusTextView;
private ImageView imageView; private ImageView imageView;
private CheckBox checkBox; private CheckBox checkBox;
private CheckBoxSquare checkBoxBig;
private AvatarDrawable avatarDrawable; private AvatarDrawable avatarDrawable;
private TLObject currentObject = null; private TLObject currentObject = null;
@ -60,7 +62,7 @@ public class UserCell extends FrameLayout {
private int radius = 32; private int radius = 32;
public UserCell(Context context, int padding) { public UserCell(Context context, int padding, int checkbox) {
super(context); super(context);
avatarDrawable = new AvatarDrawable(); avatarDrawable = new AvatarDrawable();
@ -85,10 +87,15 @@ public class UserCell extends FrameLayout {
imageView.setVisibility(GONE); imageView.setVisibility(GONE);
addView(imageView, LayoutHelper.createFrame(LayoutParams.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT) | Gravity.CENTER_VERTICAL, LocaleController.isRTL ? 0 : 16, 0, LocaleController.isRTL ? 16 : 0, 0)); addView(imageView, LayoutHelper.createFrame(LayoutParams.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT) | Gravity.CENTER_VERTICAL, LocaleController.isRTL ? 0 : 16, 0, LocaleController.isRTL ? 16 : 0, 0));
if (checkbox == 2) {
checkBoxBig = new CheckBoxSquare(context);
addView(checkBoxBig, LayoutHelper.createFrame(18, 18, (LocaleController.isRTL ? Gravity.LEFT : Gravity.RIGHT) | Gravity.CENTER_VERTICAL, LocaleController.isRTL ? 19 : 0, 0, LocaleController.isRTL ? 0 : 19, 0));
} else if (checkbox == 1) {
checkBox = new CheckBox(context, R.drawable.round_check2); checkBox = new CheckBox(context, R.drawable.round_check2);
checkBox.setVisibility(INVISIBLE); checkBox.setVisibility(INVISIBLE);
addView(checkBox, LayoutHelper.createFrame(22, 22, (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT) | Gravity.TOP, LocaleController.isRTL ? 0 : 37 + padding, 38, LocaleController.isRTL ? 37 + padding : 0, 0)); addView(checkBox, LayoutHelper.createFrame(22, 22, (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT) | Gravity.TOP, LocaleController.isRTL ? 0 : 37 + padding, 38, LocaleController.isRTL ? 37 + padding : 0, 0));
} }
}
public void setData(TLObject user, CharSequence name, CharSequence status, int resId) { public void setData(TLObject user, CharSequence name, CharSequence status, int resId) {
if (user == null) { if (user == null) {
@ -138,10 +145,23 @@ public class UserCell extends FrameLayout {
} }
public void setChecked(boolean checked, boolean animated) { public void setChecked(boolean checked, boolean animated) {
if (checkBox != null) {
if (checkBox.getVisibility() != VISIBLE) { if (checkBox.getVisibility() != VISIBLE) {
checkBox.setVisibility(VISIBLE); checkBox.setVisibility(VISIBLE);
} }
checkBox.setChecked(checked, animated); checkBox.setChecked(checked, animated);
} else if (checkBoxBig != null) {
if (checkBoxBig.getVisibility() != VISIBLE) {
checkBoxBig.setVisibility(VISIBLE);
}
checkBoxBig.setChecked(checked, animated);
}
}
public void setCheckDisabled(boolean disabled) {
if (checkBoxBig != null) {
checkBoxBig.setDisabled(disabled);
}
} }
@Override @Override
@ -231,9 +251,9 @@ public class UserCell extends FrameLayout {
statusTextView.setTextColor(statusColor); statusTextView.setTextColor(statusColor);
statusTextView.setText(currrntStatus); statusTextView.setText(currrntStatus);
} else if (currentUser != null) { } else if (currentUser != null) {
if ((currentUser.flags & TLRPC.USER_FLAG_BOT) != 0) { if (currentUser.bot) {
statusTextView.setTextColor(statusColor); statusTextView.setTextColor(statusColor);
if ((currentUser.flags & TLRPC.USER_FLAG_BOT_READING_HISTORY) != 0) { if (currentUser.bot_chat_history) {
statusTextView.setText(LocaleController.getString("BotStatusRead", R.string.BotStatusRead)); statusTextView.setText(LocaleController.getString("BotStatusRead", R.string.BotStatusRead));
} else { } else {
statusTextView.setText(LocaleController.getString("BotStatusCantRead", R.string.BotStatusCantRead)); statusTextView.setText(LocaleController.getString("BotStatusCantRead", R.string.BotStatusCantRead));

View File

@ -162,9 +162,16 @@ public class ChangeChatNameActivity extends BaseFragment {
@Override @Override
public void onTransitionAnimationEnd(boolean isOpen, boolean backward) { public void onTransitionAnimationEnd(boolean isOpen, boolean backward) {
if (isOpen) { if (isOpen) {
AndroidUtilities.runOnUIThread(new Runnable() {
@Override
public void run() {
if (firstNameField != null) {
firstNameField.requestFocus(); firstNameField.requestFocus();
AndroidUtilities.showKeyboard(firstNameField); AndroidUtilities.showKeyboard(firstNameField);
} }
}
}, 100);
}
} }
private void saveName() { private void saveName() {

View File

@ -208,8 +208,15 @@ public class ChangeNameActivity extends BaseFragment {
@Override @Override
public void onTransitionAnimationEnd(boolean isOpen, boolean backward) { public void onTransitionAnimationEnd(boolean isOpen, boolean backward) {
if (isOpen) { if (isOpen) {
AndroidUtilities.runOnUIThread(new Runnable() {
@Override
public void run() {
if (firstNameField != null) {
firstNameField.requestFocus(); firstNameField.requestFocus();
AndroidUtilities.showKeyboard(firstNameField); AndroidUtilities.showKeyboard(firstNameField);
} }
} }
}, 100);
}
}
} }

View File

@ -44,7 +44,7 @@ import org.telegram.messenger.AnimationCompat.AnimatorSetProxy;
import org.telegram.messenger.AnimationCompat.ObjectAnimatorProxy; import org.telegram.messenger.AnimationCompat.ObjectAnimatorProxy;
import org.telegram.messenger.AnimationCompat.ViewProxy; import org.telegram.messenger.AnimationCompat.ViewProxy;
import org.telegram.messenger.ApplicationLoader; import org.telegram.messenger.ApplicationLoader;
import org.telegram.messenger.BuildConfig; import org.telegram.messenger.BuildVars;
import org.telegram.messenger.FileLog; import org.telegram.messenger.FileLog;
import org.telegram.messenger.LocaleController; import org.telegram.messenger.LocaleController;
import org.telegram.messenger.MessagesController; import org.telegram.messenger.MessagesController;
@ -59,6 +59,7 @@ import org.telegram.tgnet.TLRPC;
import org.telegram.ui.ActionBar.ActionBar; import org.telegram.ui.ActionBar.ActionBar;
import org.telegram.ui.ActionBar.ActionBarMenu; import org.telegram.ui.ActionBar.ActionBarMenu;
import org.telegram.ui.ActionBar.BaseFragment; import org.telegram.ui.ActionBar.BaseFragment;
import org.telegram.ui.Components.HintEditText;
import org.telegram.ui.Components.LayoutHelper; import org.telegram.ui.Components.LayoutHelper;
import org.telegram.ui.Components.SlideView; import org.telegram.ui.Components.SlideView;
import org.telegram.ui.Components.TypefaceSpan; import org.telegram.ui.Components.TypefaceSpan;
@ -279,7 +280,7 @@ public class ChangePhoneActivity extends BaseFragment {
public class PhoneView extends SlideView implements AdapterView.OnItemSelectedListener { public class PhoneView extends SlideView implements AdapterView.OnItemSelectedListener {
private EditText codeField; private EditText codeField;
private EditText phoneField; private HintEditText phoneField;
private TextView countryButton; private TextView countryButton;
private int countryState = 0; private int countryState = 0;
@ -287,6 +288,7 @@ public class ChangePhoneActivity extends BaseFragment {
private ArrayList<String> countriesArray = new ArrayList<>(); private ArrayList<String> countriesArray = new ArrayList<>();
private HashMap<String, String> countriesMap = new HashMap<>(); private HashMap<String, String> countriesMap = new HashMap<>();
private HashMap<String, String> codesMap = new HashMap<>(); private HashMap<String, String> codesMap = new HashMap<>();
private HashMap<String, String> phoneFormatMap = new HashMap<>();
private boolean ignoreSelection = false; private boolean ignoreSelection = false;
private boolean ignoreOnTextChange = false; private boolean ignoreOnTextChange = false;
@ -307,14 +309,7 @@ public class ChangePhoneActivity extends BaseFragment {
countryButton.setEllipsize(TextUtils.TruncateAt.END); countryButton.setEllipsize(TextUtils.TruncateAt.END);
countryButton.setGravity(Gravity.LEFT | Gravity.CENTER_HORIZONTAL); countryButton.setGravity(Gravity.LEFT | Gravity.CENTER_HORIZONTAL);
countryButton.setBackgroundResource(R.drawable.spinner_states); countryButton.setBackgroundResource(R.drawable.spinner_states);
addView(countryButton); addView(countryButton, LayoutHelper.createLinear(LayoutHelper.MATCH_PARENT, 36, 20, 0, 20, 14));
LayoutParams layoutParams = (LayoutParams) countryButton.getLayoutParams();
layoutParams.width = LayoutHelper.MATCH_PARENT;
layoutParams.height = AndroidUtilities.dp(36);
layoutParams.leftMargin = AndroidUtilities.dp(20);
layoutParams.rightMargin = AndroidUtilities.dp(20);
layoutParams.bottomMargin = AndroidUtilities.dp(14);
countryButton.setLayoutParams(layoutParams);
countryButton.setOnClickListener(new OnClickListener() { countryButton.setOnClickListener(new OnClickListener() {
@Override @Override
public void onClick(View view) { public void onClick(View view) {
@ -323,7 +318,14 @@ public class ChangePhoneActivity extends BaseFragment {
@Override @Override
public void didSelectCountry(String name) { public void didSelectCountry(String name) {
selectCountry(name); selectCountry(name);
AndroidUtilities.runOnUIThread(new Runnable() {
@Override
public void run() {
AndroidUtilities.showKeyboard(phoneField);
}
}, 300);
phoneField.requestFocus(); phoneField.requestFocus();
phoneField.setSelection(phoneField.length());
} }
}); });
presentFragment(fragment); presentFragment(fragment);
@ -333,34 +335,17 @@ public class ChangePhoneActivity extends BaseFragment {
View view = new View(context); View view = new View(context);
view.setPadding(AndroidUtilities.dp(12), 0, AndroidUtilities.dp(12), 0); view.setPadding(AndroidUtilities.dp(12), 0, AndroidUtilities.dp(12), 0);
view.setBackgroundColor(0xffdbdbdb); view.setBackgroundColor(0xffdbdbdb);
addView(view); addView(view, LayoutHelper.createLinear(LayoutHelper.MATCH_PARENT, 1, 24, -17.5f, 24, 0));
layoutParams = (LayoutParams) view.getLayoutParams();
layoutParams.width = LayoutHelper.MATCH_PARENT;
layoutParams.height = 1;
layoutParams.leftMargin = AndroidUtilities.dp(24);
layoutParams.rightMargin = AndroidUtilities.dp(24);
layoutParams.topMargin = AndroidUtilities.dp(-17.5f);
view.setLayoutParams(layoutParams);
LinearLayout linearLayout = new LinearLayout(context); LinearLayout linearLayout = new LinearLayout(context);
linearLayout.setOrientation(HORIZONTAL); linearLayout.setOrientation(HORIZONTAL);
addView(linearLayout); addView(linearLayout, LayoutHelper.createLinear(LayoutHelper.MATCH_PARENT, LayoutHelper.WRAP_CONTENT, 0, 20, 0, 0));
layoutParams = (LayoutParams) linearLayout.getLayoutParams();
layoutParams.width = LayoutHelper.MATCH_PARENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.topMargin = AndroidUtilities.dp(20);
linearLayout.setLayoutParams(layoutParams);
TextView textView = new TextView(context); TextView textView = new TextView(context);
textView.setText("+"); textView.setText("+");
textView.setTextColor(0xff212121); textView.setTextColor(0xff212121);
textView.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 18); textView.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 18);
linearLayout.addView(textView); linearLayout.addView(textView, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, 24, 0, 0, 0));
layoutParams = (LayoutParams) textView.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.leftMargin = AndroidUtilities.dp(24);
textView.setLayoutParams(layoutParams);
codeField = new EditText(context); codeField = new EditText(context);
codeField.setInputType(InputType.TYPE_CLASS_PHONE); codeField.setInputType(InputType.TYPE_CLASS_PHONE);
@ -372,15 +357,9 @@ public class ChangePhoneActivity extends BaseFragment {
codeField.setGravity(Gravity.LEFT | Gravity.CENTER_VERTICAL); codeField.setGravity(Gravity.LEFT | Gravity.CENTER_VERTICAL);
codeField.setImeOptions(EditorInfo.IME_ACTION_NEXT | EditorInfo.IME_FLAG_NO_EXTRACT_UI); codeField.setImeOptions(EditorInfo.IME_ACTION_NEXT | EditorInfo.IME_FLAG_NO_EXTRACT_UI);
InputFilter[] inputFilters = new InputFilter[1]; InputFilter[] inputFilters = new InputFilter[1];
inputFilters[0] = new InputFilter.LengthFilter(4); inputFilters[0] = new InputFilter.LengthFilter(5);
codeField.setFilters(inputFilters); codeField.setFilters(inputFilters);
linearLayout.addView(codeField); linearLayout.addView(codeField, LayoutHelper.createLinear(55, 36, -9, 0, 16, 0));
layoutParams = (LayoutParams) codeField.getLayoutParams();
layoutParams.width = AndroidUtilities.dp(55);
layoutParams.height = AndroidUtilities.dp(36);
layoutParams.rightMargin = AndroidUtilities.dp(16);
layoutParams.leftMargin = AndroidUtilities.dp(-9);
codeField.setLayoutParams(layoutParams);
codeField.addTextChangedListener(new TextWatcher() { codeField.addTextChangedListener(new TextWatcher() {
@Override @Override
public void beforeTextChanged(CharSequence charSequence, int i, int i2, int i3) { public void beforeTextChanged(CharSequence charSequence, int i, int i2, int i3) {
@ -403,27 +382,58 @@ public class ChangePhoneActivity extends BaseFragment {
codeField.setText(text); codeField.setText(text);
if (text.length() == 0) { if (text.length() == 0) {
countryButton.setText(LocaleController.getString("ChooseCountry", R.string.ChooseCountry)); countryButton.setText(LocaleController.getString("ChooseCountry", R.string.ChooseCountry));
phoneField.setHintText(null);
countryState = 1; countryState = 1;
} else { } else {
String country = codesMap.get(text); String country;
boolean ok = false;
String textToSet = null;
if (text.length() > 4) {
ignoreOnTextChange = true;
for (int a = 4; a >= 1; a--) {
String sub = text.substring(0, a);
country = codesMap.get(sub);
if (country != null) {
ok = true;
textToSet = text.substring(a, text.length()) + phoneField.getText().toString();
codeField.setText(text = sub);
break;
}
}
if (!ok) {
ignoreOnTextChange = true;
textToSet = text.substring(1, text.length()) + phoneField.getText().toString();
codeField.setText(text = text.substring(0, 1));
}
}
country = codesMap.get(text);
if (country != null) { if (country != null) {
int index = countriesArray.indexOf(country); int index = countriesArray.indexOf(country);
if (index != -1) { if (index != -1) {
ignoreSelection = true; ignoreSelection = true;
countryButton.setText(countriesArray.get(index)); countryButton.setText(countriesArray.get(index));
String hint = phoneFormatMap.get(text);
updatePhoneField(); phoneField.setHintText(hint != null ? hint.replace('X', '<27>') : null);
countryState = 0; countryState = 0;
} else { } else {
countryButton.setText(LocaleController.getString("WrongCountry", R.string.WrongCountry)); countryButton.setText(LocaleController.getString("WrongCountry", R.string.WrongCountry));
phoneField.setHintText(null);
countryState = 2; countryState = 2;
} }
} else { } else {
countryButton.setText(LocaleController.getString("WrongCountry", R.string.WrongCountry)); countryButton.setText(LocaleController.getString("WrongCountry", R.string.WrongCountry));
phoneField.setHintText(null);
countryState = 2; countryState = 2;
} }
if (!ok) {
codeField.setSelection(codeField.getText().length()); codeField.setSelection(codeField.getText().length());
} }
if (textToSet != null) {
phoneField.requestFocus();
phoneField.setText(textToSet);
phoneField.setSelection(phoneField.length());
}
}
} }
}); });
codeField.setOnEditorActionListener(new TextView.OnEditorActionListener() { codeField.setOnEditorActionListener(new TextView.OnEditorActionListener() {
@ -431,13 +441,14 @@ public class ChangePhoneActivity extends BaseFragment {
public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) { public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) {
if (i == EditorInfo.IME_ACTION_NEXT) { if (i == EditorInfo.IME_ACTION_NEXT) {
phoneField.requestFocus(); phoneField.requestFocus();
phoneField.setSelection(phoneField.length());
return true; return true;
} }
return false; return false;
} }
}); });
phoneField = new EditText(context); phoneField = new HintEditText(context);
phoneField.setInputType(InputType.TYPE_CLASS_PHONE); phoneField.setInputType(InputType.TYPE_CLASS_PHONE);
phoneField.setTextColor(0xff212121); phoneField.setTextColor(0xff212121);
phoneField.getBackground().setColorFilter(AndroidUtilities.getIntColor("themeColor"), PorterDuff.Mode.SRC_IN); phoneField.getBackground().setColorFilter(AndroidUtilities.getIntColor("themeColor"), PorterDuff.Mode.SRC_IN);
@ -448,43 +459,25 @@ public class ChangePhoneActivity extends BaseFragment {
phoneField.setMaxLines(1); phoneField.setMaxLines(1);
phoneField.setGravity(Gravity.LEFT | Gravity.CENTER_VERTICAL); phoneField.setGravity(Gravity.LEFT | Gravity.CENTER_VERTICAL);
phoneField.setImeOptions(EditorInfo.IME_ACTION_NEXT | EditorInfo.IME_FLAG_NO_EXTRACT_UI); phoneField.setImeOptions(EditorInfo.IME_ACTION_NEXT | EditorInfo.IME_FLAG_NO_EXTRACT_UI);
linearLayout.addView(phoneField); linearLayout.addView(phoneField, LayoutHelper.createLinear(LayoutHelper.MATCH_PARENT, 36, 0, 0, 24, 0));
layoutParams = (LayoutParams) phoneField.getLayoutParams();
layoutParams.width = LayoutHelper.MATCH_PARENT;
layoutParams.height = AndroidUtilities.dp(36);
layoutParams.rightMargin = AndroidUtilities.dp(24);
phoneField.setLayoutParams(layoutParams);
phoneField.addTextChangedListener(new TextWatcher() { phoneField.addTextChangedListener(new TextWatcher() {
private int characterAction = -1;
private int actionPosition;
@Override @Override
public void beforeTextChanged(CharSequence s, int start, int count, int after) { public void beforeTextChanged(CharSequence s, int start, int count, int after) {
if (ignoreOnPhoneChange) { if (count == 0 && after == 1) {
return; characterAction = 1;
} } else if (count == 1 && after == 0) {
if (count == 1 && after == 0 && s.length() > 1) { if (s.charAt(start) == ' ' && start > 0) {
String phoneChars = "0123456789"; characterAction = 3;
String str = s.toString(); actionPosition = start - 1;
String substr = str.substring(start, start + 1); } else {
if (!phoneChars.contains(substr)) { characterAction = 2;
ignoreOnPhoneChange = true;
StringBuilder builder = new StringBuilder(str);
int toDelete = 0;
for (int a = start; a >= 0; a--) {
substr = str.substring(a, a + 1);
if(phoneChars.contains(substr)) {
break;
}
toDelete++;
}
builder.delete(Math.max(0, start - toDelete), start + 1);
str = builder.toString();
if (PhoneFormat.strip(str).length() == 0) {
phoneField.setText("");
} else {
phoneField.setText(str);
updatePhoneField();
}
ignoreOnPhoneChange = false;
} }
} else {
characterAction = -1;
} }
} }
@ -498,8 +491,48 @@ public class ChangePhoneActivity extends BaseFragment {
if (ignoreOnPhoneChange) { if (ignoreOnPhoneChange) {
return; return;
} }
updatePhoneField(); int start = phoneField.getSelectionStart();
} String phoneChars = "0123456789";
String str = phoneField.getText().toString();
if (characterAction == 3) {
str = str.substring(0, actionPosition) + str.substring(actionPosition + 1, str.length());
start--;
}
StringBuilder builder = new StringBuilder(str.length());
for (int a = 0; a < str.length(); a++) {
String ch = str.substring(a, a + 1);
if (phoneChars.contains(ch)) {
builder.append(ch);
}
}
ignoreOnPhoneChange = true;
String hint = phoneField.getHintText();
if (hint != null) {
for (int a = 0; a < builder.length(); a++) {
if (a < hint.length()) {
if (hint.charAt(a) == ' ') {
builder.insert(a, ' ');
a++;
if (start == a && characterAction != 2 && characterAction != 3) {
start++;
}
}
} else {
builder.insert(a, ' ');
if (start == a + 1 && characterAction != 2 && characterAction != 3) {
start++;
}
break;
}
}
}
phoneField.setText(builder);
if (start >= 0) {
phoneField.setSelection(start <= phoneField.length() ? start : phoneField.length());
}
phoneField.onTextChange();
ignoreOnPhoneChange = false;
}
}); });
phoneField.setOnEditorActionListener(new TextView.OnEditorActionListener() { phoneField.setOnEditorActionListener(new TextView.OnEditorActionListener() {
@Override @Override
@ -518,16 +551,7 @@ public class ChangePhoneActivity extends BaseFragment {
textView.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14); textView.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14);
textView.setGravity(Gravity.LEFT); textView.setGravity(Gravity.LEFT);
textView.setLineSpacing(AndroidUtilities.dp(2), 1.0f); textView.setLineSpacing(AndroidUtilities.dp(2), 1.0f);
addView(textView); addView(textView, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, Gravity.LEFT, 24, 28, 24, 10));
layoutParams = (LayoutParams) textView.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.leftMargin = AndroidUtilities.dp(24);
layoutParams.rightMargin = AndroidUtilities.dp(24);
layoutParams.topMargin = AndroidUtilities.dp(28);
layoutParams.bottomMargin = AndroidUtilities.dp(10);
layoutParams.gravity = Gravity.LEFT;
textView.setLayoutParams(layoutParams);
HashMap<String, String> languageMap = new HashMap<>(); HashMap<String, String> languageMap = new HashMap<>();
try { try {
@ -538,6 +562,9 @@ public class ChangePhoneActivity extends BaseFragment {
countriesArray.add(0, args[2]); countriesArray.add(0, args[2]);
countriesMap.put(args[2], args[0]); countriesMap.put(args[2], args[0]);
codesMap.put(args[0], args[2]); codesMap.put(args[0], args[2]);
if (args.length > 3) {
phoneFormatMap.put(args[0], args[3]);
}
languageMap.put(args[1], args[2]); languageMap.put(args[1], args[2]);
} }
reader.close(); reader.close();
@ -575,12 +602,14 @@ public class ChangePhoneActivity extends BaseFragment {
} }
if (codeField.length() == 0) { if (codeField.length() == 0) {
countryButton.setText(LocaleController.getString("ChooseCountry", R.string.ChooseCountry)); countryButton.setText(LocaleController.getString("ChooseCountry", R.string.ChooseCountry));
phoneField.setHintText(null);
countryState = 1; countryState = 1;
} }
if (codeField.length() != 0) { if (codeField.length() != 0) {
AndroidUtilities.showKeyboard(phoneField); AndroidUtilities.showKeyboard(phoneField);
phoneField.requestFocus(); phoneField.requestFocus();
phoneField.setSelection(phoneField.length());
} else { } else {
AndroidUtilities.showKeyboard(codeField); AndroidUtilities.showKeyboard(codeField);
codeField.requestFocus(); codeField.requestFocus();
@ -591,39 +620,15 @@ public class ChangePhoneActivity extends BaseFragment {
int index = countriesArray.indexOf(name); int index = countriesArray.indexOf(name);
if (index != -1) { if (index != -1) {
ignoreOnTextChange = true; ignoreOnTextChange = true;
codeField.setText(countriesMap.get(name)); String code = countriesMap.get(name);
codeField.setText(code);
countryButton.setText(name); countryButton.setText(name);
String hint = phoneFormatMap.get(code);
phoneField.setHintText(hint != null ? hint.replace('X', '<27>') : null);
countryState = 0; countryState = 0;
} }
} }
private void updatePhoneField() {
ignoreOnPhoneChange = true;
try {
String codeText = codeField.getText().toString();
String phone = PhoneFormat.getInstance().format("+" + codeText + phoneField.getText().toString());
int idx = phone.indexOf(" ");
if (idx != -1) {
String resultCode = PhoneFormat.stripExceptNumbers(phone.substring(0, idx));
if (!codeText.equals(resultCode)) {
phone = PhoneFormat.getInstance().format(phoneField.getText().toString()).trim();
phoneField.setText(phone);
int len = phoneField.length();
phoneField.setSelection(phoneField.length());
} else {
phoneField.setText(phone.substring(idx).trim());
int len = phoneField.length();
phoneField.setSelection(phoneField.length());
}
} else {
phoneField.setSelection(phoneField.length());
}
} catch (Exception e) {
FileLog.e("tmessages", e);
}
ignoreOnPhoneChange = false;
}
@Override @Override
public void onItemSelected(AdapterView<?> adapterView, View view, int i, long l) { public void onItemSelected(AdapterView<?> adapterView, View view, int i, long l) {
if (ignoreSelection) { if (ignoreSelection) {
@ -633,7 +638,6 @@ public class ChangePhoneActivity extends BaseFragment {
ignoreOnTextChange = true; ignoreOnTextChange = true;
String str = countriesArray.get(i); String str = countriesArray.get(i);
codeField.setText(countriesMap.get(str)); codeField.setText(countriesMap.get(str));
updatePhoneField();
} }
@Override @Override
@ -649,7 +653,7 @@ public class ChangePhoneActivity extends BaseFragment {
if (countryState == 1) { if (countryState == 1) {
needShowAlert(LocaleController.getString("ChooseCountry", R.string.ChooseCountry)); needShowAlert(LocaleController.getString("ChooseCountry", R.string.ChooseCountry));
return; return;
} else if (countryState == 2 && !BuildConfig.DEBUG){//!BuildVars.DEBUG_VERSION) { } else if (countryState == 2 && !BuildVars.DEBUG_VERSION) {
needShowAlert(LocaleController.getString("WrongCountry", R.string.WrongCountry)); needShowAlert(LocaleController.getString("WrongCountry", R.string.WrongCountry));
return; return;
} }
@ -707,8 +711,14 @@ public class ChangePhoneActivity extends BaseFragment {
public void onShow() { public void onShow() {
super.onShow(); super.onShow();
if (phoneField != null) { if (phoneField != null) {
AndroidUtilities.showKeyboard(phoneField); if (codeField.length() != 0) {
phoneField.setSelection(phoneField.length()); AndroidUtilities.showKeyboard(phoneField);
phoneField.requestFocus();
phoneField.setSelection(phoneField.length());
} else {
AndroidUtilities.showKeyboard(codeField);
codeField.requestFocus();
}
} }
} }
@ -734,6 +744,7 @@ public class ChangePhoneActivity extends BaseFragment {
private volatile int codeTime = 15000; private volatile int codeTime = 15000;
private double lastCurrentTime; private double lastCurrentTime;
private double lastCodeTime; private double lastCodeTime;
private boolean ignoreOnTextChange;
private boolean waitingForSms = false; private boolean waitingForSms = false;
private boolean nextPressed = false; private boolean nextPressed = false;
private String lastError = ""; private String lastError = "";
@ -776,6 +787,27 @@ public class ChangePhoneActivity extends BaseFragment {
layoutParams.leftMargin = AndroidUtilities.dp(24); layoutParams.leftMargin = AndroidUtilities.dp(24);
layoutParams.rightMargin = AndroidUtilities.dp(24); layoutParams.rightMargin = AndroidUtilities.dp(24);
codeField.setLayoutParams(layoutParams); codeField.setLayoutParams(layoutParams);
codeField.addTextChangedListener(new TextWatcher() {
@Override
public void beforeTextChanged(CharSequence s, int start, int count, int after) {
}
@Override
public void onTextChanged(CharSequence s, int start, int before, int count) {
}
@Override
public void afterTextChanged(Editable s) {
if (ignoreOnTextChange) {
return;
}
if (codeField.length() == 5) {
onNextPressed();
}
}
});
codeField.setOnEditorActionListener(new TextView.OnEditorActionListener() { codeField.setOnEditorActionListener(new TextView.OnEditorActionListener() {
@Override @Override
public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) { public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) {
@ -1073,6 +1105,7 @@ public class ChangePhoneActivity extends BaseFragment {
return; return;
} }
if (codeField != null) { if (codeField != null) {
ignoreOnTextChange = true;
codeField.setText("" + args[0]); codeField.setText("" + args[0]);
onNextPressed(); onNextPressed();
} }

File diff suppressed because it is too large Load Diff

View File

@ -120,6 +120,10 @@ public class AvatarDrawable extends Drawable {
} }
} }
public void setProfile(boolean value) {
isProfile = value;
}
public void setSmallStyle(boolean value) { public void setSmallStyle(boolean value) {
smallStyle = value; smallStyle = value;
} }
@ -129,7 +133,7 @@ public class AvatarDrawable extends Drawable {
if (id >= 0 && id < arrColors.length){//8) { if (id >= 0 && id < arrColors.length){//8) {
return id; return id;
} }
try { /*try {
String str; String str;
if (id >= 0) { if (id >= 0) {
str = String.format(Locale.US, "%d%d", id, UserConfig.getClientUserId()); str = String.format(Locale.US, "%d%d", id, UserConfig.getClientUserId());
@ -148,8 +152,8 @@ public class AvatarDrawable extends Drawable {
return Math.abs(b) % arrColors.length; return Math.abs(b) % arrColors.length;
} catch (Exception e) { } catch (Exception e) {
FileLog.e("tmessages", e); FileLog.e("tmessages", e);
} }*/
return id % arrColors.length; return Math.abs(id % arrColors.length);
} }
public static int getColorNameIndex(int id) { public static int getColorNameIndex(int id) {

View File

@ -749,7 +749,7 @@ public class ChatActivityEnterView extends FrameLayoutFixed implements Notificat
return isAsAdmin; return isAsAdmin;
} }
public void showTopView(boolean animated) { public void showTopView(boolean animated, final boolean openKeyboard) {
if (topView == null || topViewShowed || getVisibility() != VISIBLE) { if (topView == null || topViewShowed || getVisibility() != VISIBLE) {
return; return;
} }
@ -772,7 +772,7 @@ public class ChatActivityEnterView extends FrameLayoutFixed implements Notificat
public void onAnimationEnd(Object animation) { public void onAnimationEnd(Object animation) {
if (currentTopViewAnimation != null && currentTopViewAnimation.equals(animation)) { if (currentTopViewAnimation != null && currentTopViewAnimation.equals(animation)) {
setTopViewAnimation(1.0f); setTopViewAnimation(1.0f);
if (!forceShowSendButton) { if (!forceShowSendButton || openKeyboard) {
openKeyboard(); openKeyboard();
} }
currentTopViewAnimation = null; currentTopViewAnimation = null;
@ -783,7 +783,7 @@ public class ChatActivityEnterView extends FrameLayoutFixed implements Notificat
currentTopViewAnimation.start(); currentTopViewAnimation.start();
} else { } else {
setTopViewAnimation(1.0f); setTopViewAnimation(1.0f);
if (!forceShowSendButton) { if (!forceShowSendButton || openKeyboard) {
openKeyboard(); openKeyboard();
} }
} }
@ -888,6 +888,7 @@ public class ChatActivityEnterView extends FrameLayoutFixed implements Notificat
public void onPause() { public void onPause() {
isPaused = true; isPaused = true;
closeKeyboard();
} }
public void onResume() { public void onResume() {
@ -908,8 +909,8 @@ public class ChatActivityEnterView extends FrameLayoutFixed implements Notificat
dialog_id = id; dialog_id = id;
if ((int) dialog_id < 0) { if ((int) dialog_id < 0) {
TLRPC.Chat currentChat = MessagesController.getInstance().getChat(-(int) dialog_id); TLRPC.Chat currentChat = MessagesController.getInstance().getChat(-(int) dialog_id);
isAsAdmin = ChatObject.isChannel(currentChat) && ((currentChat.flags & TLRPC.CHAT_FLAG_ADMIN) != 0 || (currentChat.flags & TLRPC.CHAT_FLAG_USER_IS_EDITOR) != 0); isAsAdmin = ChatObject.isChannel(currentChat) && (currentChat.creator || currentChat.editor) && !currentChat.megagroup;
adminModeAvailable = isAsAdmin && (currentChat.flags & TLRPC.CHAT_FLAG_IS_BROADCAST) == 0; adminModeAvailable = isAsAdmin && !currentChat.broadcast;
if (adminModeAvailable) { if (adminModeAvailable) {
SharedPreferences preferences = ApplicationLoader.applicationContext.getSharedPreferences("mainconfig", Activity.MODE_PRIVATE); SharedPreferences preferences = ApplicationLoader.applicationContext.getSharedPreferences("mainconfig", Activity.MODE_PRIVATE);
isAsAdmin = preferences.getBoolean("asadmin_" + dialog_id, true); isAsAdmin = preferences.getBoolean("asadmin_" + dialog_id, true);
@ -924,8 +925,9 @@ public class ChatActivityEnterView extends FrameLayoutFixed implements Notificat
private void updateFieldHint() { private void updateFieldHint() {
boolean isChannel = false; boolean isChannel = false;
if ((int) dialog_id < 0 && ChatObject.isChannel(MessagesController.getInstance().getChat(-(int) dialog_id))) { if ((int) dialog_id < 0) {
isChannel = true; TLRPC.Chat chat = MessagesController.getInstance().getChat(-(int) dialog_id);
isChannel = ChatObject.isChannel(chat) && !chat.megagroup;
} }
if (isChannel) { if (isChannel) {
messageEditText.setHint(isAsAdmin ? LocaleController.getString("ChannelBroadcast", R.string.ChannelBroadcast) : LocaleController.getString("ChannelComment", R.string.ChannelComment)); messageEditText.setHint(isAsAdmin ? LocaleController.getString("ChannelBroadcast", R.string.ChannelBroadcast) : LocaleController.getString("ChannelComment", R.string.ChannelComment));
@ -1005,9 +1007,9 @@ public class ChatActivityEnterView extends FrameLayoutFixed implements Notificat
} }
private String getTrimmedString(String src) { private String getTrimmedString(String src) {
String result = src.trim(); src = src.trim();
if (result.length() == 0) { if (src.length() == 0) {
return result; return src;
} }
while (src.startsWith("\n")) { while (src.startsWith("\n")) {
src = src.substring(1); src = src.substring(1);
@ -1299,13 +1301,18 @@ public class ChatActivityEnterView extends FrameLayoutFixed implements Notificat
this.delegate = delegate; this.delegate = delegate;
} }
public void setCommand(MessageObject messageObject, String command, boolean longPress) { public void setCommand(MessageObject messageObject, String command, boolean longPress, boolean username) {
if (command == null || getVisibility() != VISIBLE) { if (command == null || getVisibility() != VISIBLE) {
return; return;
} }
if (longPress) { if (longPress) {
String text = messageEditText.getText().toString(); String text = messageEditText.getText().toString();
TLRPC.User user = messageObject != null && (int) dialog_id < 0 ? MessagesController.getInstance().getUser(messageObject.messageOwner.from_id) : null;
if ((botCount != 1 || username) && user != null && user.bot && !command.contains("@")) {
text = String.format(Locale.US, "%s@%s", command, user.username) + " " + text.replaceFirst("^/[a-zA-Z@\\d_]{1,255}(\\s|$)", "");
} else {
text = command + " " + text.replaceFirst("^/[a-zA-Z@\\d_]{1,255}(\\s|$)", ""); text = command + " " + text.replaceFirst("^/[a-zA-Z@\\d_]{1,255}(\\s|$)", "");
}
ignoreTextChange = true; ignoreTextChange = true;
messageEditText.setText(text); messageEditText.setText(text);
messageEditText.setSelection(messageEditText.getText().length()); messageEditText.setSelection(messageEditText.getText().length());
@ -1315,7 +1322,7 @@ public class ChatActivityEnterView extends FrameLayoutFixed implements Notificat
} }
} else { } else {
TLRPC.User user = messageObject != null && (int) dialog_id < 0 ? MessagesController.getInstance().getUser(messageObject.messageOwner.from_id) : null; TLRPC.User user = messageObject != null && (int) dialog_id < 0 ? MessagesController.getInstance().getUser(messageObject.messageOwner.from_id) : null;
if (botCount != 1 && user != null && (user.flags & TLRPC.USER_FLAG_BOT) != 0 && !command.contains("@")) { if ((botCount != 1 || username) && user != null && user.bot && !command.contains("@")) {
SendMessagesHelper.getInstance().sendMessage(String.format(Locale.US, "%s@%s", command, user.username), dialog_id, null, null, false, asAdmin()); SendMessagesHelper.getInstance().sendMessage(String.format(Locale.US, "%s@%s", command, user.username), dialog_id, null, null, false, asAdmin());
} else { } else {
SendMessagesHelper.getInstance().sendMessage(command, dialog_id, null, null, false, asAdmin()); SendMessagesHelper.getInstance().sendMessage(command, dialog_id, null, null, false, asAdmin());
@ -1477,7 +1484,7 @@ public class ChatActivityEnterView extends FrameLayoutFixed implements Notificat
if (replyingMessageObject != null) { if (replyingMessageObject != null) {
openKeyboardInternal(); openKeyboardInternal();
setButtons(botMessageObject, false); setButtons(botMessageObject, false);
} else if ((botButtonsMessageObject.messageOwner.reply_markup.flags & 2) != 0) { } else if (botButtonsMessageObject.messageOwner.reply_markup.single_use) {
openKeyboardInternal(); openKeyboardInternal();
SharedPreferences preferences = ApplicationLoader.applicationContext.getSharedPreferences("mainconfig", Activity.MODE_PRIVATE); SharedPreferences preferences = ApplicationLoader.applicationContext.getSharedPreferences("mainconfig", Activity.MODE_PRIVATE);
preferences.edit().putInt("answered_" + dialog_id, botButtonsMessageObject.getId()).commit(); preferences.edit().putInt("answered_" + dialog_id, botButtonsMessageObject.getId()).commit();
@ -1497,7 +1504,7 @@ public class ChatActivityEnterView extends FrameLayoutFixed implements Notificat
if (botReplyMarkup != null) { if (botReplyMarkup != null) {
SharedPreferences preferences = ApplicationLoader.applicationContext.getSharedPreferences("mainconfig", Activity.MODE_PRIVATE); SharedPreferences preferences = ApplicationLoader.applicationContext.getSharedPreferences("mainconfig", Activity.MODE_PRIVATE);
boolean keyboardHidden = preferences.getInt("hidekeyboard_" + dialog_id, 0) == messageObject.getId(); boolean keyboardHidden = preferences.getInt("hidekeyboard_" + dialog_id, 0) == messageObject.getId();
if (botButtonsMessageObject != replyingMessageObject && (botReplyMarkup.flags & 2) != 0) { if (botButtonsMessageObject != replyingMessageObject && botReplyMarkup.single_use) {
if (preferences.getInt("answered_" + dialog_id, 0) == messageObject.getId()) { if (preferences.getInt("answered_" + dialog_id, 0) == messageObject.getId()) {
return; return;
} }
@ -1680,6 +1687,10 @@ public class ChatActivityEnterView extends FrameLayoutFixed implements Notificat
AndroidUtilities.showKeyboard(messageEditText); AndroidUtilities.showKeyboard(messageEditText);
} }
public void closeKeyboard() {
AndroidUtilities.hideKeyboard(messageEditText);
}
public boolean isPopupShowing() { public boolean isPopupShowing() {
return emojiView != null && emojiView.getVisibility() == VISIBLE || botKeyboardView != null && botKeyboardView.getVisibility() == VISIBLE; return emojiView != null && emojiView.getVisibility() == VISIBLE || botKeyboardView != null && botKeyboardView.getVisibility() == VISIBLE;
} }

View File

@ -1213,7 +1213,7 @@ public class EmojiView extends FrameLayout implements NotificationCenter.Notific
ArrayList<TLRPC.TL_messages_stickerSet> packs = StickersQuery.getStickerSets(); ArrayList<TLRPC.TL_messages_stickerSet> packs = StickersQuery.getStickerSets();
for (int a = 0; a < packs.size(); a++) { for (int a = 0; a < packs.size(); a++) {
TLRPC.TL_messages_stickerSet pack = packs.get(a); TLRPC.TL_messages_stickerSet pack = packs.get(a);
if ((pack.set.flags & 2) != 0 || pack.documents == null || pack.documents.isEmpty()) { if (pack.set.disabled || pack.documents == null || pack.documents.isEmpty()) {
continue; continue;
} }
stickerSets.add(pack); stickerSets.add(pack);

View File

@ -151,7 +151,11 @@ public class FrameLayoutFixed extends FrameLayout {
} }
} catch (Exception e) { } catch (Exception e) {
FileLog.e("tmessages", e); FileLog.e("tmessages", e);
super.onMeasure(widthMeasureSpec, heightMeasureSpec); try {
super.onMeasure(widthMeasureSpec, heightMeasureSpec);
} catch (Exception e2) {
FileLog.e("tmessages", e2);
}
} }
} }
} }

View File

@ -11,6 +11,7 @@ package org.telegram.ui.Components;
import android.widget.FrameLayout; import android.widget.FrameLayout;
import android.widget.LinearLayout; import android.widget.LinearLayout;
import android.widget.RelativeLayout; import android.widget.RelativeLayout;
import android.widget.ScrollView;
import org.telegram.messenger.AndroidUtilities; import org.telegram.messenger.AndroidUtilities;
@ -23,6 +24,10 @@ public class LayoutHelper {
return (int) (size < 0 ? size : AndroidUtilities.dp(size)); return (int) (size < 0 ? size : AndroidUtilities.dp(size));
} }
public static FrameLayout.LayoutParams createScroll(int width, int height, int gravity) {
return new ScrollView.LayoutParams(getSize(width), getSize(height), gravity);
}
public static FrameLayout.LayoutParams createFrame(int width, float height, int gravity, float leftMargin, float topMargin, float rightMargin, float bottomMargin) { public static FrameLayout.LayoutParams createFrame(int width, float height, int gravity, float leftMargin, float topMargin, float rightMargin, float bottomMargin) {
FrameLayout.LayoutParams layoutParams = new FrameLayout.LayoutParams(getSize(width), getSize(height), gravity); FrameLayout.LayoutParams layoutParams = new FrameLayout.LayoutParams(getSize(width), getSize(height), gravity);
layoutParams.setMargins(AndroidUtilities.dp(leftMargin), AndroidUtilities.dp(topMargin), AndroidUtilities.dp(rightMargin), AndroidUtilities.dp(bottomMargin)); layoutParams.setMargins(AndroidUtilities.dp(leftMargin), AndroidUtilities.dp(topMargin), AndroidUtilities.dp(rightMargin), AndroidUtilities.dp(bottomMargin));
@ -100,7 +105,7 @@ public class LayoutHelper {
return layoutParams; return layoutParams;
} }
public static LinearLayout.LayoutParams createLinear(int width, int height, int leftMargin, int topMargin, int rightMargin, int bottomMargin) { public static LinearLayout.LayoutParams createLinear(int width, int height, float leftMargin, float topMargin, float rightMargin, float bottomMargin) {
LinearLayout.LayoutParams layoutParams = new LinearLayout.LayoutParams(getSize(width), getSize(height)); LinearLayout.LayoutParams layoutParams = new LinearLayout.LayoutParams(getSize(width), getSize(height));
layoutParams.setMargins(AndroidUtilities.dp(leftMargin), AndroidUtilities.dp(topMargin), AndroidUtilities.dp(rightMargin), AndroidUtilities.dp(bottomMargin)); layoutParams.setMargins(AndroidUtilities.dp(leftMargin), AndroidUtilities.dp(topMargin), AndroidUtilities.dp(rightMargin), AndroidUtilities.dp(bottomMargin));
return layoutParams; return layoutParams;

View File

@ -1155,7 +1155,7 @@ public class PasscodeView extends FrameLayout {
if (UserConfig.passcodeType == 1 && (AndroidUtilities.isTablet() || getContext().getResources().getConfiguration().orientation != Configuration.ORIENTATION_LANDSCAPE)) { if (UserConfig.passcodeType == 1 && (AndroidUtilities.isTablet() || getContext().getResources().getConfiguration().orientation != Configuration.ORIENTATION_LANDSCAPE)) {
int t = 0; int t = 0;
if ((Integer) passwordFrameLayout.getTag() != 0) { //Don't change if ((Integer) passwordFrameLayout.getTag() != 0) {
t = (Integer) passwordFrameLayout.getTag(); t = (Integer) passwordFrameLayout.getTag();
} }
LayoutParams layoutParams = (LayoutParams) passwordFrameLayout.getLayoutParams(); LayoutParams layoutParams = (LayoutParams) passwordFrameLayout.getLayoutParams();

View File

@ -41,6 +41,8 @@ public class ResourceLoader {
public static Drawable mediaBackgroundDrawable; public static Drawable mediaBackgroundDrawable;
public static Drawable clockChannelDrawable; public static Drawable clockChannelDrawable;
public static Drawable[][] shareDrawable = new Drawable[2][2];
public static Drawable viewsCountDrawable; public static Drawable viewsCountDrawable;
public static Drawable viewsOutCountDrawable; public static Drawable viewsOutCountDrawable;
public static Drawable viewsMediaCountDrawable; public static Drawable viewsMediaCountDrawable;
@ -132,6 +134,11 @@ public class ResourceLoader {
docMenuInDrawable = context.getResources().getDrawable(R.drawable.doc_actions_b); docMenuInDrawable = context.getResources().getDrawable(R.drawable.doc_actions_b);
docMenuOutDrawable = context.getResources().getDrawable(R.drawable.doc_actions_g); docMenuOutDrawable = context.getResources().getDrawable(R.drawable.doc_actions_g);
shareDrawable[0][0] = context.getResources().getDrawable(R.drawable.shareblue);
shareDrawable[0][1] = context.getResources().getDrawable(R.drawable.shareblue_pressed);
shareDrawable[1][0] = context.getResources().getDrawable(R.drawable.shareblack);
shareDrawable[1][1] = context.getResources().getDrawable(R.drawable.shareblack_pressed);
geoInDrawable = context.getResources().getDrawable(R.drawable.location_b); geoInDrawable = context.getResources().getDrawable(R.drawable.location_b);
geoOutDrawable = context.getResources().getDrawable(R.drawable.location_g); geoOutDrawable = context.getResources().getDrawable(R.drawable.location_g);

View File

@ -80,6 +80,7 @@ public class ContactsActivity extends BaseFragment implements NotificationCenter
private boolean returnAsResult; private boolean returnAsResult;
private boolean createSecretChat; private boolean createSecretChat;
private boolean creatingChat = false; private boolean creatingChat = false;
private boolean allowBots = true;
private boolean needForwardCount = true; private boolean needForwardCount = true;
private int chat_id; private int chat_id;
private String selectAlertString = null; private String selectAlertString = null;
@ -111,6 +112,7 @@ public class ContactsActivity extends BaseFragment implements NotificationCenter
selectAlertString = arguments.getString("selectAlertString"); selectAlertString = arguments.getString("selectAlertString");
allowUsernameSearch = arguments.getBoolean("allowUsernameSearch", true); allowUsernameSearch = arguments.getBoolean("allowUsernameSearch", true);
needForwardCount = arguments.getBoolean("needForwardCount", true); needForwardCount = arguments.getBoolean("needForwardCount", true);
allowBots = arguments.getBoolean("allowBots", true);
chat_id = arguments.getInt("chat_id", 0); chat_id = arguments.getInt("chat_id", 0);
} else { } else {
needPhonebook = true; needPhonebook = true;
@ -222,7 +224,7 @@ public class ContactsActivity extends BaseFragment implements NotificationCenter
clear.setColorFilter(AndroidUtilities.getIntDef("contactsHeaderIconsColor", 0xffffffff), PorterDuff.Mode.MULTIPLY); clear.setColorFilter(AndroidUtilities.getIntDef("contactsHeaderIconsColor", 0xffffffff), PorterDuff.Mode.MULTIPLY);
item.getClearButton().setImageDrawable(clear); item.getClearButton().setImageDrawable(clear);
searchListViewAdapter = new SearchAdapter(context, ignoreUsers, allowUsernameSearch, false, false); searchListViewAdapter = new SearchAdapter(context, ignoreUsers, allowUsernameSearch, false, false, allowBots);
listViewAdapter = new ContactsAdapter(context, onlyUsers ? 1 : 0, needPhonebook, ignoreUsers, chat_id != 0); listViewAdapter = new ContactsAdapter(context, onlyUsers ? 1 : 0, needPhonebook, ignoreUsers, chat_id != 0);
fragmentView = new FrameLayout(context); fragmentView = new FrameLayout(context);
@ -436,7 +438,7 @@ public class ContactsActivity extends BaseFragment implements NotificationCenter
if (getParentActivity() == null) { if (getParentActivity() == null) {
return; return;
} }
if ((user.flags & TLRPC.USER_FLAG_BOT) != 0 && (user.flags & TLRPC.USER_FLAG_BOT_CANT_JOIN_GROUP) != 0) { if (user.bot && user.bot_nochats) {
try { try {
Toast.makeText(getParentActivity(), LocaleController.getString("BotCantJoinGroups", R.string.BotCantJoinGroups), Toast.LENGTH_SHORT).show(); Toast.makeText(getParentActivity(), LocaleController.getString("BotCantJoinGroups", R.string.BotCantJoinGroups), Toast.LENGTH_SHORT).show();
} catch (Exception e) { } catch (Exception e) {
@ -448,7 +450,7 @@ public class ContactsActivity extends BaseFragment implements NotificationCenter
builder.setTitle(LocaleController.getString("AppName", R.string.AppName)); builder.setTitle(LocaleController.getString("AppName", R.string.AppName));
String message = LocaleController.formatStringSimple(selectAlertString, UserObject.getUserName(user)); String message = LocaleController.formatStringSimple(selectAlertString, UserObject.getUserName(user));
EditText editText = null; EditText editText = null;
if ((user.flags & TLRPC.USER_FLAG_BOT) == 0 && needForwardCount) { if (!user.bot && needForwardCount) {
message = String.format("%s\n\n%s", message, LocaleController.getString("AddToTheGroupForwardCount", R.string.AddToTheGroupForwardCount)); message = String.format("%s\n\n%s", message, LocaleController.getString("AddToTheGroupForwardCount", R.string.AddToTheGroupForwardCount));
editText = new EditText(getParentActivity()); editText = new EditText(getParentActivity());
if (android.os.Build.VERSION.SDK_INT < 11) { if (android.os.Build.VERSION.SDK_INT < 11) {

View File

@ -198,10 +198,10 @@ public class CountrySelectActivity extends BaseFragment {
if (i < 0) { if (i < 0) {
return; return;
} }
finishFragment();
if (country != null && delegate != null) { if (country != null && delegate != null) {
delegate.didSelectCountry(country.name); delegate.didSelectCountry(country.name);
} }
finishFragment();
} }
}); });

View File

@ -160,7 +160,7 @@ public class GroupCreateActivity extends BaseFragment implements NotificationCen
ActionBarMenu menu = actionBar.createMenu(); ActionBarMenu menu = actionBar.createMenu();
menu.addItemWithWidth(done_button, R.drawable.ic_done, AndroidUtilities.dp(56)); menu.addItemWithWidth(done_button, R.drawable.ic_done, AndroidUtilities.dp(56));
searchListViewAdapter = new SearchAdapter(context, null, false, false, false); searchListViewAdapter = new SearchAdapter(context, null, false, false, false, false);
searchListViewAdapter.setCheckedMap(selectedContacts); searchListViewAdapter.setCheckedMap(selectedContacts);
searchListViewAdapter.setUseUserCell(true); searchListViewAdapter.setUseUserCell(true);
listViewAdapter = new ContactsAdapter(context, 1, false, null, false); listViewAdapter = new ContactsAdapter(context, 1, false, null, false);

View File

@ -450,7 +450,7 @@ public class GroupCreateFinalActivity extends BaseFragment implements Notificati
@Override @Override
public View getView(int i, View view, ViewGroup viewGroup) { public View getView(int i, View view, ViewGroup viewGroup) {
if (view == null) { if (view == null) {
view = new UserCell(mContext, 1); view = new UserCell(mContext, 1, 0);
} }
TLRPC.User user = MessagesController.getInstance().getUser(selectedContacts.get(i)); TLRPC.User user = MessagesController.getInstance().getUser(selectedContacts.get(i));

View File

@ -178,9 +178,6 @@ public class GroupInviteActivity extends BaseFragment implements NotificationCen
@Override @Override
public void didReceivedNotification(int id, Object... args) { public void didReceivedNotification(int id, Object... args) {
if (id == NotificationCenter.chatInfoDidLoaded) { if (id == NotificationCenter.chatInfoDidLoaded) {
if (args.length != 2) {
return;
}
TLRPC.ChatFull info = (TLRPC.ChatFull) args[0]; TLRPC.ChatFull info = (TLRPC.ChatFull) args[0];
int guid = (int) args[1]; int guid = (int) args[1];
if (info.id == chat_id && guid == classGuid) { if (info.id == chat_id && guid == classGuid) {
@ -309,7 +306,8 @@ public class GroupInviteActivity extends BaseFragment implements NotificationCen
((TextInfoPrivacyCell) view).setText(""); ((TextInfoPrivacyCell) view).setText("");
view.setBackgroundResource(R.drawable.greydivider_bottom); view.setBackgroundResource(R.drawable.greydivider_bottom);
} else if (i == linkInfoRow) { } else if (i == linkInfoRow) {
if (ChatObject.isChannel(chat_id)) { TLRPC.Chat chat = MessagesController.getInstance().getChat(chat_id);
if (ChatObject.isChannel(chat) && !chat.megagroup) {
((TextInfoPrivacyCell) view).setText(LocaleController.getString("ChannelLinkInfo", R.string.ChannelLinkInfo)); ((TextInfoPrivacyCell) view).setText(LocaleController.getString("ChannelLinkInfo", R.string.ChannelLinkInfo));
} else { } else {
((TextInfoPrivacyCell) view).setText(LocaleController.getString("LinkInfo", R.string.LinkInfo)); ((TextInfoPrivacyCell) view).setText(LocaleController.getString("LinkInfo", R.string.LinkInfo));

View File

@ -28,10 +28,13 @@ import android.widget.ImageView;
import android.widget.TextView; import android.widget.TextView;
import org.telegram.messenger.AndroidUtilities; import org.telegram.messenger.AndroidUtilities;
import org.telegram.messenger.BuildConfig;
import org.telegram.messenger.LocaleController; import org.telegram.messenger.LocaleController;
import org.telegram.messenger.R; import org.telegram.messenger.R;
import org.telegram.tgnet.ConnectionsManager;
public class IntroActivity extends Activity { public class IntroActivity extends Activity {
private ViewPager viewPager; private ViewPager viewPager;
private ImageView topImage1; private ImageView topImage1;
private ImageView topImage2; private ImageView topImage2;
@ -57,7 +60,7 @@ public class IntroActivity extends Activity {
} }
if (LocaleController.isRTL) { if (LocaleController.isRTL) {
icons = new int[] { icons = new int[]{
R.drawable.intro7, R.drawable.intro7,
R.drawable.intro6, R.drawable.intro6,
R.drawable.intro5, R.drawable.intro5,
@ -66,7 +69,7 @@ public class IntroActivity extends Activity {
R.drawable.intro2, R.drawable.intro2,
R.drawable.intro1 R.drawable.intro1
}; };
titles = new int[] { titles = new int[]{
R.string.Page7Title, R.string.Page7Title,
R.string.Page6Title, R.string.Page6Title,
R.string.Page5Title, R.string.Page5Title,
@ -75,7 +78,7 @@ public class IntroActivity extends Activity {
R.string.Page2Title, R.string.Page2Title,
R.string.Page1Title R.string.Page1Title
}; };
messages = new int[] { messages = new int[]{
R.string.Page7Message, R.string.Page7Message,
R.string.Page6Message, R.string.Page6Message,
R.string.Page5Message, R.string.Page5Message,
@ -85,7 +88,7 @@ public class IntroActivity extends Activity {
R.string.Page1Message R.string.Page1Message
}; };
} else { } else {
icons = new int[] { icons = new int[]{
R.drawable.intro1, R.drawable.intro1,
R.drawable.intro2, R.drawable.intro2,
R.drawable.intro3, R.drawable.intro3,
@ -94,7 +97,7 @@ public class IntroActivity extends Activity {
R.drawable.intro6, R.drawable.intro6,
R.drawable.intro7 R.drawable.intro7
}; };
titles = new int[] { titles = new int[]{
R.string.Page1Title, R.string.Page1Title,
R.string.Page2Title, R.string.Page2Title,
R.string.Page3Title, R.string.Page3Title,
@ -103,7 +106,7 @@ public class IntroActivity extends Activity {
R.string.Page6Title, R.string.Page6Title,
R.string.Page7Title R.string.Page7Title
}; };
messages = new int[] { messages = new int[]{
R.string.Page1Message, R.string.Page1Message,
R.string.Page2Message, R.string.Page2Message,
R.string.Page3Message, R.string.Page3Message,
@ -113,18 +116,18 @@ public class IntroActivity extends Activity {
R.string.Page7Message R.string.Page7Message
}; };
} }
viewPager = (ViewPager)findViewById(R.id.intro_view_pager); viewPager = (ViewPager) findViewById(R.id.intro_view_pager);
TextView startMessagingButton = (TextView) findViewById(R.id.start_messaging_button); TextView startMessagingButton = (TextView) findViewById(R.id.start_messaging_button);
startMessagingButton.setText(LocaleController.getString("StartMessaging", R.string.StartMessaging).toUpperCase()); startMessagingButton.setText(LocaleController.getString("StartMessaging", R.string.StartMessaging).toUpperCase());
if (Build.VERSION.SDK_INT >= 21) { if (Build.VERSION.SDK_INT >= 21) {
StateListAnimator animator = new StateListAnimator(); StateListAnimator animator = new StateListAnimator();
animator.addState(new int[] {android.R.attr.state_pressed}, ObjectAnimator.ofFloat(startMessagingButton, "translationZ", AndroidUtilities.dp(2), AndroidUtilities.dp(4)).setDuration(200)); animator.addState(new int[]{android.R.attr.state_pressed}, ObjectAnimator.ofFloat(startMessagingButton, "translationZ", AndroidUtilities.dp(2), AndroidUtilities.dp(4)).setDuration(200));
animator.addState(new int[] {}, ObjectAnimator.ofFloat(startMessagingButton, "translationZ", AndroidUtilities.dp(4), AndroidUtilities.dp(2)).setDuration(200)); animator.addState(new int[]{}, ObjectAnimator.ofFloat(startMessagingButton, "translationZ", AndroidUtilities.dp(4), AndroidUtilities.dp(2)).setDuration(200));
startMessagingButton.setStateListAnimator(animator); startMessagingButton.setStateListAnimator(animator);
} }
topImage1 = (ImageView)findViewById(R.id.icon_image1); topImage1 = (ImageView) findViewById(R.id.icon_image1);
topImage2 = (ImageView)findViewById(R.id.icon_image2); topImage2 = (ImageView) findViewById(R.id.icon_image2);
bottomPages = (ViewGroup)findViewById(R.id.bottom_pages); bottomPages = (ViewGroup) findViewById(R.id.bottom_pages);
topImage2.setVisibility(View.GONE); topImage2.setVisibility(View.GONE);
viewPager.setAdapter(new IntroAdapter()); viewPager.setAdapter(new IntroAdapter());
viewPager.setPageMargin(0); viewPager.setPageMargin(0);
@ -218,6 +221,15 @@ public class IntroActivity extends Activity {
finish(); finish();
} }
}); });
if (BuildConfig.DEBUG) {
startMessagingButton.setOnLongClickListener(new View.OnLongClickListener() {
@Override
public boolean onLongClick(View v) {
ConnectionsManager.getInstance().switchBackend();
return true;
}
});
}
justCreated = true; justCreated = true;
} }
@ -254,8 +266,8 @@ public class IntroActivity extends Activity {
@Override @Override
public Object instantiateItem(ViewGroup container, int position) { public Object instantiateItem(ViewGroup container, int position) {
View view = View.inflate(container.getContext(), R.layout.intro_view_layout, null); View view = View.inflate(container.getContext(), R.layout.intro_view_layout, null);
TextView headerTextView = (TextView)view.findViewById(R.id.header_text); TextView headerTextView = (TextView) view.findViewById(R.id.header_text);
TextView messageTextView = (TextView)view.findViewById(R.id.message_text); TextView messageTextView = (TextView) view.findViewById(R.id.message_text);
container.addView(view, 0); container.addView(view, 0);
headerTextView.setText(getString(titles[position])); headerTextView.setText(getString(titles[position]));

View File

@ -292,7 +292,7 @@ public class LastSeenUsersActivity extends BaseFragment implements NotificationC
int type = getItemViewType(i); int type = getItemViewType(i);
if (type == 0) { if (type == 0) {
if (view == null) { if (view == null) {
view = new UserCell(mContext, 1); view = new UserCell(mContext, 1, 0);
} }
TLRPC.User user = MessagesController.getInstance().getUser(uidArray.get(i)); TLRPC.User user = MessagesController.getInstance().getUser(uidArray.get(i));
((UserCell)view).setData(user, null, user.phone != null && user.phone.length() != 0 ? PhoneFormat.getInstance().format("+" + user.phone) : LocaleController.getString("NumberUnknown", R.string.NumberUnknown), 0); ((UserCell)view).setData(user, null, user.phone != null && user.phone.length() != 0 ? PhoneFormat.getInstance().format("+" + user.phone) : LocaleController.getString("NumberUnknown", R.string.NumberUnknown), 0);

View File

@ -94,6 +94,7 @@ public class LaunchActivity extends Activity implements ActionBarLayout.ActionBa
private static ArrayList<BaseFragment> mainFragmentsStack = new ArrayList<>(); private static ArrayList<BaseFragment> mainFragmentsStack = new ArrayList<>();
private static ArrayList<BaseFragment> layerFragmentsStack = new ArrayList<>(); private static ArrayList<BaseFragment> layerFragmentsStack = new ArrayList<>();
private static ArrayList<BaseFragment> rightFragmentsStack = new ArrayList<>(); private static ArrayList<BaseFragment> rightFragmentsStack = new ArrayList<>();
private ViewTreeObserver.OnGlobalLayoutListener onGlobalLayoutListener;
private ActionBarLayout actionBarLayout; private ActionBarLayout actionBarLayout;
private ActionBarLayout layersActionBarLayout; private ActionBarLayout layersActionBarLayout;
@ -518,6 +519,18 @@ public class LaunchActivity extends Activity implements ActionBarLayout.ActionBa
handleIntent(getIntent(), false, savedInstanceState != null, false); handleIntent(getIntent(), false, savedInstanceState != null, false);
needLayout(); needLayout();
final View view = getWindow().getDecorView().getRootView();
view.getViewTreeObserver().addOnGlobalLayoutListener(onGlobalLayoutListener = new ViewTreeObserver.OnGlobalLayoutListener() {
@Override
public void onGlobalLayout() {
int height = view.getMeasuredHeight();
if (height > AndroidUtilities.dp(100) && height < AndroidUtilities.displaySize.y && height + AndroidUtilities.dp(100) > AndroidUtilities.displaySize.y) {
AndroidUtilities.displaySize.y = height;
FileLog.e("tmessages", "fix display size y to " + AndroidUtilities.displaySize.y);
}
}
});
} }
private void showPasscodeActivity() { private void showPasscodeActivity() {
@ -959,8 +972,13 @@ public class LaunchActivity extends Activity implements ActionBarLayout.ActionBa
if (dialogId == 0) { if (dialogId == 0) {
Bundle args = new Bundle(); Bundle args = new Bundle();
args.putBoolean("onlySelect", true); args.putBoolean("onlySelect", true);
if (contactsToSend != null) {
args.putString("selectAlertString", LocaleController.getString("SendContactTo", R.string.SendMessagesTo));
args.putString("selectAlertStringGroup", LocaleController.getString("SendContactToGroup", R.string.SendContactToGroup));
} else {
args.putString("selectAlertString", LocaleController.getString("SendMessagesTo", R.string.SendMessagesTo)); args.putString("selectAlertString", LocaleController.getString("SendMessagesTo", R.string.SendMessagesTo));
args.putString("selectAlertStringGroup", LocaleController.getString("SendMessagesToGroup", R.string.SendMessagesToGroup)); args.putString("selectAlertStringGroup", LocaleController.getString("SendMessagesToGroup", R.string.SendMessagesToGroup));
}
DialogsActivity fragment = new DialogsActivity(args); DialogsActivity fragment = new DialogsActivity(args);
fragment.setDelegate(this); fragment.setDelegate(this);
boolean removeLast; boolean removeLast;
@ -1064,7 +1082,7 @@ public class LaunchActivity extends Activity implements ActionBarLayout.ActionBa
if (botChat != null) { if (botChat != null) {
final TLRPC.User user = !res.users.isEmpty() ? res.users.get(0) : null; final TLRPC.User user = !res.users.isEmpty() ? res.users.get(0) : null;
if (user == null || (user.flags & TLRPC.USER_FLAG_BOT) != 0 && (user.flags & TLRPC.USER_FLAG_BOT_CANT_JOIN_GROUP) != 0) { if (user == null || user.bot && user.bot_nochats) {
try { try {
Toast.makeText(LaunchActivity.this, LocaleController.getString("BotCantJoinGroups", R.string.BotCantJoinGroups), Toast.LENGTH_SHORT).show(); Toast.makeText(LaunchActivity.this, LocaleController.getString("BotCantJoinGroups", R.string.BotCantJoinGroups), Toast.LENGTH_SHORT).show();
} catch (Exception e) { } catch (Exception e) {
@ -1096,7 +1114,7 @@ public class LaunchActivity extends Activity implements ActionBarLayout.ActionBa
} else { } else {
args.putInt("user_id", res.users.get(0).id); args.putInt("user_id", res.users.get(0).id);
} }
if (botUser != null) { if (botUser != null && res.users.size() > 0 && res.users.get(0).bot) {
args.putString("botUser", botUser); args.putString("botUser", botUser);
} }
ChatActivity fragment = new ChatActivity(args); ChatActivity fragment = new ChatActivity(args);
@ -1146,7 +1164,7 @@ public class LaunchActivity extends Activity implements ActionBarLayout.ActionBa
} else { } else {
AlertDialog.Builder builder = new AlertDialog.Builder(LaunchActivity.this); AlertDialog.Builder builder = new AlertDialog.Builder(LaunchActivity.this);
builder.setTitle(LocaleController.getString("AppName", R.string.AppName)); builder.setTitle(LocaleController.getString("AppName", R.string.AppName));
if ((invite.flags & 1) != 0 || ChatObject.isChannel(invite.chat)) { if (!invite.megagroup && invite.channel || ChatObject.isChannel(invite.chat) && !invite.chat.megagroup) {
builder.setMessage(LocaleController.formatString("ChannelJoinTo", R.string.ChannelJoinTo, invite.chat != null ? invite.chat.title : invite.title)); builder.setMessage(LocaleController.formatString("ChannelJoinTo", R.string.ChannelJoinTo, invite.chat != null ? invite.chat.title : invite.title));
} else { } else {
builder.setMessage(LocaleController.formatString("JoinToGroup", R.string.JoinToGroup, invite.chat != null ? invite.chat.title : invite.title)); builder.setMessage(LocaleController.formatString("JoinToGroup", R.string.JoinToGroup, invite.chat != null ? invite.chat.title : invite.title));
@ -1613,6 +1631,18 @@ public class LaunchActivity extends Activity implements ActionBarLayout.ActionBa
} catch (Exception e) { } catch (Exception e) {
FileLog.e("tmessages", e); FileLog.e("tmessages", e);
} }
try {
if (onGlobalLayoutListener != null) {
final View view = getWindow().getDecorView().getRootView();
if (Build.VERSION.SDK_INT < 16) {
view.getViewTreeObserver().removeGlobalOnLayoutListener(onGlobalLayoutListener);
} else {
view.getViewTreeObserver().removeOnGlobalLayoutListener(onGlobalLayoutListener);
}
}
} catch (Exception e) {
FileLog.e("tmessages", e);
}
super.onDestroy(); super.onDestroy();
onFinish(); onFinish();
} }

View File

@ -48,7 +48,6 @@ import android.widget.TextView;
import org.telegram.PhoneFormat.PhoneFormat; import org.telegram.PhoneFormat.PhoneFormat;
import org.telegram.messenger.AndroidUtilities; import org.telegram.messenger.AndroidUtilities;
import org.telegram.messenger.ApplicationLoader; import org.telegram.messenger.ApplicationLoader;
import org.telegram.messenger.BuildConfig;
import org.telegram.messenger.BuildVars; import org.telegram.messenger.BuildVars;
import org.telegram.messenger.ContactsController; import org.telegram.messenger.ContactsController;
import org.telegram.messenger.FileLog; import org.telegram.messenger.FileLog;
@ -66,6 +65,7 @@ import org.telegram.tgnet.TLRPC;
import org.telegram.ui.ActionBar.ActionBar; import org.telegram.ui.ActionBar.ActionBar;
import org.telegram.ui.ActionBar.ActionBarMenu; import org.telegram.ui.ActionBar.ActionBarMenu;
import org.telegram.ui.ActionBar.BaseFragment; import org.telegram.ui.ActionBar.BaseFragment;
import org.telegram.ui.Components.HintEditText;
import org.telegram.ui.Components.LayoutHelper; import org.telegram.ui.Components.LayoutHelper;
import org.telegram.ui.Components.SlideView; import org.telegram.ui.Components.SlideView;
import org.telegram.ui.Components.TypefaceSpan; import org.telegram.ui.Components.TypefaceSpan;
@ -131,12 +131,7 @@ public class LoginActivity extends BaseFragment {
scrollView.setFillViewport(true); scrollView.setFillViewport(true);
FrameLayout frameLayout = new FrameLayout(context); FrameLayout frameLayout = new FrameLayout(context);
scrollView.addView(frameLayout); scrollView.addView(frameLayout, LayoutHelper.createScroll(LayoutHelper.MATCH_PARENT, LayoutHelper.WRAP_CONTENT, Gravity.TOP | Gravity.LEFT));
ScrollView.LayoutParams layoutParams = (ScrollView.LayoutParams) frameLayout.getLayoutParams();
layoutParams.width = ScrollView.LayoutParams.MATCH_PARENT;
layoutParams.height = ScrollView.LayoutParams.WRAP_CONTENT;
layoutParams.gravity = Gravity.TOP | Gravity.LEFT;
frameLayout.setLayoutParams(layoutParams);
views[0] = new PhoneView(context); views[0] = new PhoneView(context);
views[1] = new LoginActivitySmsView(context); views[1] = new LoginActivitySmsView(context);
@ -146,15 +141,7 @@ public class LoginActivity extends BaseFragment {
for (int a = 0; a < 5; a++) { for (int a = 0; a < 5; a++) {
views[a].setVisibility(a == 0 ? View.VISIBLE : View.GONE); views[a].setVisibility(a == 0 ? View.VISIBLE : View.GONE);
frameLayout.addView(views[a]); frameLayout.addView(views[a], LayoutHelper.createFrame(LayoutHelper.MATCH_PARENT, a == 0 ? LayoutHelper.WRAP_CONTENT : LayoutHelper.MATCH_PARENT, Gravity.TOP | Gravity.LEFT, AndroidUtilities.isTablet() ? 26 : 18, 30, AndroidUtilities.isTablet() ? 26 : 18, 0));
FrameLayout.LayoutParams layoutParams1 = (FrameLayout.LayoutParams) views[a].getLayoutParams();
layoutParams1.width = LayoutHelper.MATCH_PARENT;
layoutParams1.height = a == 0 ? LayoutHelper.WRAP_CONTENT : LayoutHelper.MATCH_PARENT;
layoutParams1.leftMargin = AndroidUtilities.dp(AndroidUtilities.isTablet() ? 26 : 18);
layoutParams1.rightMargin = AndroidUtilities.dp(AndroidUtilities.isTablet() ? 26 : 18);
layoutParams1.topMargin = AndroidUtilities.dp(30);
layoutParams1.gravity = Gravity.TOP | Gravity.LEFT;
views[a].setLayoutParams(layoutParams1);
} }
Bundle savedInstanceState = loadCurrentState(); Bundle savedInstanceState = loadCurrentState();
@ -398,7 +385,7 @@ public class LoginActivity extends BaseFragment {
public class PhoneView extends SlideView implements AdapterView.OnItemSelectedListener { public class PhoneView extends SlideView implements AdapterView.OnItemSelectedListener {
private EditText codeField; private EditText codeField;
private EditText phoneField; private HintEditText phoneField;
private TextView countryButton; private TextView countryButton;
private int countryState = 0; private int countryState = 0;
@ -406,13 +393,14 @@ public class LoginActivity extends BaseFragment {
private ArrayList<String> countriesArray = new ArrayList<>(); private ArrayList<String> countriesArray = new ArrayList<>();
private HashMap<String, String> countriesMap = new HashMap<>(); private HashMap<String, String> countriesMap = new HashMap<>();
private HashMap<String, String> codesMap = new HashMap<>(); private HashMap<String, String> codesMap = new HashMap<>();
private HashMap<String, String> phoneFormatMap = new HashMap<>();
private boolean ignoreSelection = false; private boolean ignoreSelection = false;
private boolean ignoreOnTextChange = false; private boolean ignoreOnTextChange = false;
private boolean ignoreOnPhoneChange = false; private boolean ignoreOnPhoneChange = false;
private boolean nextPressed = false; private boolean nextPressed = false;
public PhoneView(Context context) { public PhoneView(final Context context) {
super(context); super(context);
setOrientation(VERTICAL); setOrientation(VERTICAL);
@ -426,12 +414,7 @@ public class LoginActivity extends BaseFragment {
countryButton.setEllipsize(TextUtils.TruncateAt.END); countryButton.setEllipsize(TextUtils.TruncateAt.END);
countryButton.setGravity((LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT) | Gravity.CENTER_HORIZONTAL); countryButton.setGravity((LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT) | Gravity.CENTER_HORIZONTAL);
countryButton.setBackgroundResource(R.drawable.spinner_states); countryButton.setBackgroundResource(R.drawable.spinner_states);
addView(countryButton); addView(countryButton, LayoutHelper.createLinear(LayoutHelper.MATCH_PARENT, 36, 0, 0, 0, 14));
LayoutParams layoutParams = (LayoutParams) countryButton.getLayoutParams();
layoutParams.width = LayoutHelper.MATCH_PARENT;
layoutParams.height = AndroidUtilities.dp(36);
layoutParams.bottomMargin = AndroidUtilities.dp(14);
countryButton.setLayoutParams(layoutParams);
countryButton.setOnClickListener(new OnClickListener() { countryButton.setOnClickListener(new OnClickListener() {
@Override @Override
public void onClick(View view) { public void onClick(View view) {
@ -440,7 +423,14 @@ public class LoginActivity extends BaseFragment {
@Override @Override
public void didSelectCountry(String name) { public void didSelectCountry(String name) {
selectCountry(name); selectCountry(name);
AndroidUtilities.runOnUIThread(new Runnable() {
@Override
public void run() {
AndroidUtilities.showKeyboard(phoneField);
}
}, 300);
phoneField.requestFocus(); phoneField.requestFocus();
phoneField.setSelection(phoneField.length());
} }
}); });
presentFragment(fragment); presentFragment(fragment);
@ -450,33 +440,17 @@ public class LoginActivity extends BaseFragment {
View view = new View(context); View view = new View(context);
view.setPadding(AndroidUtilities.dp(12), 0, AndroidUtilities.dp(12), 0); view.setPadding(AndroidUtilities.dp(12), 0, AndroidUtilities.dp(12), 0);
view.setBackgroundColor(0xffdbdbdb); view.setBackgroundColor(0xffdbdbdb);
addView(view); addView(view, LayoutHelper.createLinear(LayoutHelper.MATCH_PARENT, 1, 4, -17.5f, 4, 0));
layoutParams = (LayoutParams) view.getLayoutParams();
layoutParams.width = LayoutHelper.MATCH_PARENT;
layoutParams.height = 1;
layoutParams.topMargin = AndroidUtilities.dp(-17.5f);
layoutParams.leftMargin = AndroidUtilities.dp(4);
layoutParams.rightMargin = AndroidUtilities.dp(4);
view.setLayoutParams(layoutParams);
LinearLayout linearLayout = new LinearLayout(context); LinearLayout linearLayout = new LinearLayout(context);
linearLayout.setOrientation(HORIZONTAL); linearLayout.setOrientation(HORIZONTAL);
addView(linearLayout); addView(linearLayout, LayoutHelper.createLinear(LayoutHelper.MATCH_PARENT, LayoutHelper.WRAP_CONTENT, 0, 20, 0, 0));
layoutParams = (LayoutParams) linearLayout.getLayoutParams();
layoutParams.width = LayoutHelper.MATCH_PARENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.topMargin = AndroidUtilities.dp(20);
linearLayout.setLayoutParams(layoutParams);
TextView textView = new TextView(context); TextView textView = new TextView(context);
textView.setText("+"); textView.setText("+");
textView.setTextColor(0xff212121); textView.setTextColor(0xff212121);
textView.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 18); textView.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 18);
linearLayout.addView(textView); linearLayout.addView(textView, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT));
layoutParams = (LayoutParams) textView.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
textView.setLayoutParams(layoutParams);
codeField = new EditText(context); codeField = new EditText(context);
codeField.setInputType(InputType.TYPE_CLASS_PHONE); codeField.setInputType(InputType.TYPE_CLASS_PHONE);
@ -488,15 +462,9 @@ public class LoginActivity extends BaseFragment {
codeField.setGravity(Gravity.LEFT | Gravity.CENTER_VERTICAL); codeField.setGravity(Gravity.LEFT | Gravity.CENTER_VERTICAL);
codeField.setImeOptions(EditorInfo.IME_ACTION_NEXT | EditorInfo.IME_FLAG_NO_EXTRACT_UI); codeField.setImeOptions(EditorInfo.IME_ACTION_NEXT | EditorInfo.IME_FLAG_NO_EXTRACT_UI);
InputFilter[] inputFilters = new InputFilter[1]; InputFilter[] inputFilters = new InputFilter[1];
inputFilters[0] = new InputFilter.LengthFilter(4); inputFilters[0] = new InputFilter.LengthFilter(5);
codeField.setFilters(inputFilters); codeField.setFilters(inputFilters);
linearLayout.addView(codeField); linearLayout.addView(codeField, LayoutHelper.createLinear(55, 36, -9, 0, 16, 0));
layoutParams = (LayoutParams) codeField.getLayoutParams();
layoutParams.width = AndroidUtilities.dp(55);
layoutParams.height = AndroidUtilities.dp(36);
layoutParams.rightMargin = AndroidUtilities.dp(16);
layoutParams.leftMargin = AndroidUtilities.dp(-9);
codeField.setLayoutParams(layoutParams);
codeField.addTextChangedListener(new TextWatcher() { codeField.addTextChangedListener(new TextWatcher() {
@Override @Override
public void beforeTextChanged(CharSequence charSequence, int i, int i2, int i3) { public void beforeTextChanged(CharSequence charSequence, int i, int i2, int i3) {
@ -519,27 +487,58 @@ public class LoginActivity extends BaseFragment {
codeField.setText(text); codeField.setText(text);
if (text.length() == 0) { if (text.length() == 0) {
countryButton.setText(LocaleController.getString("ChooseCountry", R.string.ChooseCountry)); countryButton.setText(LocaleController.getString("ChooseCountry", R.string.ChooseCountry));
phoneField.setHintText(null);
countryState = 1; countryState = 1;
} else { } else {
String country = codesMap.get(text); String country;
boolean ok = false;
String textToSet = null;
if (text.length() > 4) {
ignoreOnTextChange = true;
for (int a = 4; a >= 1; a--) {
String sub = text.substring(0, a);
country = codesMap.get(sub);
if (country != null) {
ok = true;
textToSet = text.substring(a, text.length()) + phoneField.getText().toString();
codeField.setText(text = sub);
break;
}
}
if (!ok) {
ignoreOnTextChange = true;
textToSet = text.substring(1, text.length()) + phoneField.getText().toString();
codeField.setText(text = text.substring(0, 1));
}
}
country = codesMap.get(text);
if (country != null) { if (country != null) {
int index = countriesArray.indexOf(country); int index = countriesArray.indexOf(country);
if (index != -1) { if (index != -1) {
ignoreSelection = true; ignoreSelection = true;
countryButton.setText(countriesArray.get(index)); countryButton.setText(countriesArray.get(index));
String hint = phoneFormatMap.get(text);
updatePhoneField(); phoneField.setHintText(hint != null ? hint.replace('X', '<27>') : null);
countryState = 0; countryState = 0;
} else { } else {
countryButton.setText(LocaleController.getString("WrongCountry", R.string.WrongCountry)); countryButton.setText(LocaleController.getString("WrongCountry", R.string.WrongCountry));
phoneField.setHintText(null);
countryState = 2; countryState = 2;
} }
} else { } else {
countryButton.setText(LocaleController.getString("WrongCountry", R.string.WrongCountry)); countryButton.setText(LocaleController.getString("WrongCountry", R.string.WrongCountry));
phoneField.setHintText(null);
countryState = 2; countryState = 2;
} }
if (!ok) {
codeField.setSelection(codeField.getText().length()); codeField.setSelection(codeField.getText().length());
} }
if (textToSet != null) {
phoneField.requestFocus();
phoneField.setText(textToSet);
phoneField.setSelection(phoneField.length());
}
}
} }
}); });
codeField.setOnEditorActionListener(new TextView.OnEditorActionListener() { codeField.setOnEditorActionListener(new TextView.OnEditorActionListener() {
@ -547,13 +546,14 @@ public class LoginActivity extends BaseFragment {
public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) { public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) {
if (i == EditorInfo.IME_ACTION_NEXT) { if (i == EditorInfo.IME_ACTION_NEXT) {
phoneField.requestFocus(); phoneField.requestFocus();
phoneField.setSelection(phoneField.length());
return true; return true;
} }
return false; return false;
} }
}); });
phoneField = new EditText(context); phoneField = new HintEditText(context);
phoneField.setInputType(InputType.TYPE_CLASS_PHONE); phoneField.setInputType(InputType.TYPE_CLASS_PHONE);
phoneField.setTextColor(0xff212121); phoneField.setTextColor(0xff212121);
phoneField.setHintTextColor(0xff979797); phoneField.setHintTextColor(0xff979797);
@ -564,42 +564,25 @@ public class LoginActivity extends BaseFragment {
phoneField.setMaxLines(1); phoneField.setMaxLines(1);
phoneField.setGravity(Gravity.LEFT | Gravity.CENTER_VERTICAL); phoneField.setGravity(Gravity.LEFT | Gravity.CENTER_VERTICAL);
phoneField.setImeOptions(EditorInfo.IME_ACTION_NEXT | EditorInfo.IME_FLAG_NO_EXTRACT_UI); phoneField.setImeOptions(EditorInfo.IME_ACTION_NEXT | EditorInfo.IME_FLAG_NO_EXTRACT_UI);
linearLayout.addView(phoneField); linearLayout.addView(phoneField, LayoutHelper.createFrame(LayoutHelper.MATCH_PARENT, 36));
layoutParams = (LayoutParams) phoneField.getLayoutParams();
layoutParams.width = LayoutHelper.MATCH_PARENT;
layoutParams.height = AndroidUtilities.dp(36);
phoneField.setLayoutParams(layoutParams);
phoneField.addTextChangedListener(new TextWatcher() { phoneField.addTextChangedListener(new TextWatcher() {
private int characterAction = -1;
private int actionPosition;
@Override @Override
public void beforeTextChanged(CharSequence s, int start, int count, int after) { public void beforeTextChanged(CharSequence s, int start, int count, int after) {
if (ignoreOnPhoneChange) { if (count == 0 && after == 1) {
return; characterAction = 1;
} } else if (count == 1 && after == 0) {
if (count == 1 && after == 0 && s.length() > 1) { if (s.charAt(start) == ' ' && start > 0) {
String phoneChars = "0123456789"; characterAction = 3;
String str = s.toString(); actionPosition = start - 1;
String substr = str.substring(start, start + 1); } else {
if (!phoneChars.contains(substr)) { characterAction = 2;
ignoreOnPhoneChange = true;
StringBuilder builder = new StringBuilder(str);
int toDelete = 0;
for (int a = start; a >= 0; a--) {
substr = str.substring(a, a + 1);
if (phoneChars.contains(substr)) {
break;
}
toDelete++;
}
builder.delete(Math.max(0, start - toDelete), start + 1);
str = builder.toString();
if (PhoneFormat.strip(str).length() == 0) {
phoneField.setText("");
} else {
phoneField.setText(str);
updatePhoneField();
}
ignoreOnPhoneChange = false;
} }
} else {
characterAction = -1;
} }
} }
@ -613,8 +596,48 @@ public class LoginActivity extends BaseFragment {
if (ignoreOnPhoneChange) { if (ignoreOnPhoneChange) {
return; return;
} }
updatePhoneField(); int start = phoneField.getSelectionStart();
} String phoneChars = "0123456789";
String str = phoneField.getText().toString();
if (characterAction == 3) {
str = str.substring(0, actionPosition) + str.substring(actionPosition + 1, str.length());
start--;
}
StringBuilder builder = new StringBuilder(str.length());
for (int a = 0; a < str.length(); a++) {
String ch = str.substring(a, a + 1);
if (phoneChars.contains(ch)) {
builder.append(ch);
}
}
ignoreOnPhoneChange = true;
String hint = phoneField.getHintText();
if (hint != null) {
for (int a = 0; a < builder.length(); a++) {
if (a < hint.length()) {
if (hint.charAt(a) == ' ') {
builder.insert(a, ' ');
a++;
if (start == a && characterAction != 2 && characterAction != 3) {
start++;
}
}
} else {
builder.insert(a, ' ');
if (start == a + 1 && characterAction != 2 && characterAction != 3) {
start++;
}
break;
}
}
}
phoneField.setText(builder);
if (start >= 0) {
phoneField.setSelection(start <= phoneField.length() ? start : phoneField.length());
}
phoneField.onTextChange();
ignoreOnPhoneChange = false;
}
}); });
phoneField.setOnEditorActionListener(new TextView.OnEditorActionListener() { phoneField.setOnEditorActionListener(new TextView.OnEditorActionListener() {
@Override @Override
@ -633,14 +656,7 @@ public class LoginActivity extends BaseFragment {
textView.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14); textView.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14);
textView.setGravity(LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT); textView.setGravity(LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
textView.setLineSpacing(AndroidUtilities.dp(2), 1.0f); textView.setLineSpacing(AndroidUtilities.dp(2), 1.0f);
addView(textView); addView(textView, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT, 0, 28, 0, 10));
layoutParams = (LayoutParams) textView.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.topMargin = AndroidUtilities.dp(28);
layoutParams.bottomMargin = AndroidUtilities.dp(10);
layoutParams.gravity = LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT;
textView.setLayoutParams(layoutParams);
HashMap<String, String> languageMap = new HashMap<>(); HashMap<String, String> languageMap = new HashMap<>();
try { try {
@ -651,6 +667,9 @@ public class LoginActivity extends BaseFragment {
countriesArray.add(0, args[2]); countriesArray.add(0, args[2]);
countriesMap.put(args[2], args[0]); countriesMap.put(args[2], args[0]);
codesMap.put(args[0], args[2]); codesMap.put(args[0], args[2]);
if (args.length > 3) {
phoneFormatMap.put(args[0], args[3]);
}
languageMap.put(args[1], args[2]); languageMap.put(args[1], args[2]);
} }
reader.close(); reader.close();
@ -688,12 +707,14 @@ public class LoginActivity extends BaseFragment {
} }
if (codeField.length() == 0) { if (codeField.length() == 0) {
countryButton.setText(LocaleController.getString("ChooseCountry", R.string.ChooseCountry)); countryButton.setText(LocaleController.getString("ChooseCountry", R.string.ChooseCountry));
phoneField.setHintText(null);
countryState = 1; countryState = 1;
} }
if (codeField.length() != 0) { if (codeField.length() != 0) {
AndroidUtilities.showKeyboard(phoneField); AndroidUtilities.showKeyboard(phoneField);
phoneField.requestFocus(); phoneField.requestFocus();
phoneField.setSelection(phoneField.length());
} else { } else {
AndroidUtilities.showKeyboard(codeField); AndroidUtilities.showKeyboard(codeField);
codeField.requestFocus(); codeField.requestFocus();
@ -704,37 +725,15 @@ public class LoginActivity extends BaseFragment {
int index = countriesArray.indexOf(name); int index = countriesArray.indexOf(name);
if (index != -1) { if (index != -1) {
ignoreOnTextChange = true; ignoreOnTextChange = true;
codeField.setText(countriesMap.get(name)); String code = countriesMap.get(name);
codeField.setText(code);
countryButton.setText(name); countryButton.setText(name);
String hint = phoneFormatMap.get(code);
phoneField.setHintText(hint != null ? hint.replace('X', '<27>') : null);
countryState = 0; countryState = 0;
} }
} }
private void updatePhoneField() {
ignoreOnPhoneChange = true;
try {
String codeText = codeField.getText().toString();
String phone = PhoneFormat.getInstance().format("+" + codeText + phoneField.getText().toString());
int idx = phone.indexOf(" ");
if (idx != -1) {
String resultCode = PhoneFormat.stripExceptNumbers(phone.substring(0, idx));
if (!codeText.equals(resultCode)) {
phone = PhoneFormat.getInstance().format(phoneField.getText().toString()).trim();
phoneField.setText(phone);
phoneField.setSelection(phoneField.length());
} else {
phoneField.setText(phone.substring(idx).trim());
phoneField.setSelection(phoneField.length());
}
} else {
phoneField.setSelection(phoneField.length());
}
} catch (Exception e) {
FileLog.e("tmessages", e);
}
ignoreOnPhoneChange = false;
}
@Override @Override
public void onItemSelected(AdapterView<?> adapterView, View view, int i, long l) { public void onItemSelected(AdapterView<?> adapterView, View view, int i, long l) {
if (ignoreSelection) { if (ignoreSelection) {
@ -744,7 +743,6 @@ public class LoginActivity extends BaseFragment {
ignoreOnTextChange = true; ignoreOnTextChange = true;
String str = countriesArray.get(i); String str = countriesArray.get(i);
codeField.setText(countriesMap.get(str)); codeField.setText(countriesMap.get(str));
updatePhoneField();
} }
@Override @Override
@ -760,7 +758,7 @@ public class LoginActivity extends BaseFragment {
if (countryState == 1) { if (countryState == 1) {
needShowAlert(LocaleController.getString("AppName", R.string.AppName), LocaleController.getString("ChooseCountry", R.string.ChooseCountry)); needShowAlert(LocaleController.getString("AppName", R.string.AppName), LocaleController.getString("ChooseCountry", R.string.ChooseCountry));
return; return;
} else if (countryState == 2 && !BuildConfig.DEBUG){//!BuildVars.DEBUG_VERSION) { } else if (countryState == 2 && !BuildVars.DEBUG_VERSION) {
needShowAlert(LocaleController.getString("AppName", R.string.AppName), LocaleController.getString("WrongCountry", R.string.WrongCountry)); needShowAlert(LocaleController.getString("AppName", R.string.AppName), LocaleController.getString("WrongCountry", R.string.WrongCountry));
return; return;
} }
@ -831,8 +829,14 @@ public class LoginActivity extends BaseFragment {
public void onShow() { public void onShow() {
super.onShow(); super.onShow();
if (phoneField != null) { if (phoneField != null) {
phoneField.requestFocus(); if (codeField.length() != 0) {
phoneField.setSelection(phoneField.length()); AndroidUtilities.showKeyboard(phoneField);
phoneField.requestFocus();
phoneField.setSelection(phoneField.length());
} else {
AndroidUtilities.showKeyboard(codeField);
codeField.requestFocus();
}
} }
} }
@ -884,6 +888,7 @@ public class LoginActivity extends BaseFragment {
private volatile int codeTime = 15000; private volatile int codeTime = 15000;
private double lastCurrentTime; private double lastCurrentTime;
private double lastCodeTime; private double lastCodeTime;
private boolean ignoreOnTextChange = false;
private boolean waitingForSms = false; private boolean waitingForSms = false;
private boolean nextPressed = false; private boolean nextPressed = false;
private String lastError = ""; private String lastError = "";
@ -898,12 +903,7 @@ public class LoginActivity extends BaseFragment {
confirmTextView.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14); confirmTextView.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14);
confirmTextView.setGravity(LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT); confirmTextView.setGravity(LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
confirmTextView.setLineSpacing(AndroidUtilities.dp(2), 1.0f); confirmTextView.setLineSpacing(AndroidUtilities.dp(2), 1.0f);
addView(confirmTextView); addView(confirmTextView, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT));
LayoutParams layoutParams = (LayoutParams) confirmTextView.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.gravity = LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT;
confirmTextView.setLayoutParams(layoutParams);
codeField = new EditText(context); codeField = new EditText(context);
codeField.setTextColor(0xff212121); codeField.setTextColor(0xff212121);
@ -918,13 +918,28 @@ public class LoginActivity extends BaseFragment {
codeField.setInputType(InputType.TYPE_CLASS_PHONE); codeField.setInputType(InputType.TYPE_CLASS_PHONE);
codeField.setMaxLines(1); codeField.setMaxLines(1);
codeField.setPadding(0, 0, 0, 0); codeField.setPadding(0, 0, 0, 0);
addView(codeField); addView(codeField, LayoutHelper.createLinear(LayoutHelper.MATCH_PARENT, 36, Gravity.CENTER_HORIZONTAL, 0, 20, 0, 0));
layoutParams = (LayoutParams) codeField.getLayoutParams(); codeField.addTextChangedListener(new TextWatcher() {
layoutParams.width = LayoutHelper.MATCH_PARENT; @Override
layoutParams.height = AndroidUtilities.dp(36); public void beforeTextChanged(CharSequence s, int start, int count, int after) {
layoutParams.gravity = Gravity.CENTER_HORIZONTAL;
layoutParams.topMargin = AndroidUtilities.dp(20); }
codeField.setLayoutParams(layoutParams);
@Override
public void onTextChanged(CharSequence s, int start, int before, int count) {
}
@Override
public void afterTextChanged(Editable s) {
if (ignoreOnTextChange) {
return;
}
if (codeField.length() == 5) {
onNextPressed();
}
}
});
codeField.setOnEditorActionListener(new TextView.OnEditorActionListener() { codeField.setOnEditorActionListener(new TextView.OnEditorActionListener() {
@Override @Override
public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) { public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) {
@ -941,13 +956,7 @@ public class LoginActivity extends BaseFragment {
timeText.setTextColor(0xff757575); timeText.setTextColor(0xff757575);
timeText.setLineSpacing(AndroidUtilities.dp(2), 1.0f); timeText.setLineSpacing(AndroidUtilities.dp(2), 1.0f);
timeText.setGravity(LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT); timeText.setGravity(LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
addView(timeText); addView(timeText, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT, 0, 30, 0, 0));
layoutParams = (LayoutParams) timeText.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.gravity = LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT;
layoutParams.topMargin = AndroidUtilities.dp(30);
timeText.setLayoutParams(layoutParams);
problemText = new TextView(context); problemText = new TextView(context);
problemText.setText(LocaleController.getString("DidNotGetTheCode", R.string.DidNotGetTheCode)); problemText.setText(LocaleController.getString("DidNotGetTheCode", R.string.DidNotGetTheCode));
@ -958,13 +967,7 @@ public class LoginActivity extends BaseFragment {
problemText.setTextColor(defColor); problemText.setTextColor(defColor);
problemText.setLineSpacing(AndroidUtilities.dp(2), 1.0f); problemText.setLineSpacing(AndroidUtilities.dp(2), 1.0f);
problemText.setPadding(0, AndroidUtilities.dp(2), 0, AndroidUtilities.dp(12)); problemText.setPadding(0, AndroidUtilities.dp(2), 0, AndroidUtilities.dp(12));
addView(problemText); addView(problemText, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT, 0, 20, 0, 0));
layoutParams = (LayoutParams) problemText.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.gravity = LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT;
layoutParams.topMargin = AndroidUtilities.dp(20);
problemText.setLayoutParams(layoutParams);
problemText.setOnClickListener(new OnClickListener() { problemText.setOnClickListener(new OnClickListener() {
@Override @Override
public void onClick(View v) { public void onClick(View v) {
@ -986,12 +989,7 @@ public class LoginActivity extends BaseFragment {
LinearLayout linearLayout = new LinearLayout(context); LinearLayout linearLayout = new LinearLayout(context);
linearLayout.setGravity((LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT) | Gravity.CENTER_VERTICAL); linearLayout.setGravity((LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT) | Gravity.CENTER_VERTICAL);
addView(linearLayout); addView(linearLayout, LayoutHelper.createLinear(LayoutHelper.MATCH_PARENT, LayoutHelper.MATCH_PARENT, LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT));
layoutParams = (LayoutParams) linearLayout.getLayoutParams();
layoutParams.width = LayoutHelper.MATCH_PARENT;
layoutParams.height = LayoutHelper.MATCH_PARENT;
layoutParams.gravity = (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
linearLayout.setLayoutParams(layoutParams);
TextView wrongNumber = new TextView(context); TextView wrongNumber = new TextView(context);
wrongNumber.setGravity((LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT) | Gravity.CENTER_HORIZONTAL); wrongNumber.setGravity((LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT) | Gravity.CENTER_HORIZONTAL);
@ -1000,13 +998,7 @@ public class LoginActivity extends BaseFragment {
wrongNumber.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14); wrongNumber.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14);
wrongNumber.setLineSpacing(AndroidUtilities.dp(2), 1.0f); wrongNumber.setLineSpacing(AndroidUtilities.dp(2), 1.0f);
wrongNumber.setPadding(0, AndroidUtilities.dp(24), 0, 0); wrongNumber.setPadding(0, AndroidUtilities.dp(24), 0, 0);
linearLayout.addView(wrongNumber); linearLayout.addView(wrongNumber, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, Gravity.BOTTOM | (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT), 0, 0, 0, 10));
layoutParams = (LayoutParams) wrongNumber.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.gravity = Gravity.BOTTOM | (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
layoutParams.bottomMargin = AndroidUtilities.dp(10);
wrongNumber.setLayoutParams(layoutParams);
wrongNumber.setText(LocaleController.getString("WrongNumber", R.string.WrongNumber)); wrongNumber.setText(LocaleController.getString("WrongNumber", R.string.WrongNumber));
wrongNumber.setOnClickListener(new OnClickListener() { wrongNumber.setOnClickListener(new OnClickListener() {
@Override @Override
@ -1305,6 +1297,7 @@ public class LoginActivity extends BaseFragment {
return; return;
} }
if (codeField != null) { if (codeField != null) {
ignoreOnTextChange = true;
codeField.setText("" + args[0]); codeField.setText("" + args[0]);
onNextPressed(); onNextPressed();
} }
@ -1370,12 +1363,7 @@ public class LoginActivity extends BaseFragment {
confirmTextView.setGravity(LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT); confirmTextView.setGravity(LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
confirmTextView.setLineSpacing(AndroidUtilities.dp(2), 1.0f); confirmTextView.setLineSpacing(AndroidUtilities.dp(2), 1.0f);
confirmTextView.setText(LocaleController.getString("LoginPasswordText", R.string.LoginPasswordText)); confirmTextView.setText(LocaleController.getString("LoginPasswordText", R.string.LoginPasswordText));
addView(confirmTextView); addView(confirmTextView, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT));
LayoutParams layoutParams = (LayoutParams) confirmTextView.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.gravity = LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT;
confirmTextView.setLayoutParams(layoutParams);
codeField = new EditText(context); codeField = new EditText(context);
codeField.setTextColor(0xff212121); codeField.setTextColor(0xff212121);
@ -1390,13 +1378,7 @@ public class LoginActivity extends BaseFragment {
codeField.setTransformationMethod(PasswordTransformationMethod.getInstance()); codeField.setTransformationMethod(PasswordTransformationMethod.getInstance());
codeField.setTypeface(Typeface.DEFAULT); codeField.setTypeface(Typeface.DEFAULT);
codeField.setGravity(LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT); codeField.setGravity(LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
addView(codeField); addView(codeField, LayoutHelper.createLinear(LayoutHelper.MATCH_PARENT, 36, Gravity.CENTER_HORIZONTAL, 0, 20, 0, 0));
layoutParams = (LayoutParams) codeField.getLayoutParams();
layoutParams.width = LayoutHelper.MATCH_PARENT;
layoutParams.height = AndroidUtilities.dp(36);
layoutParams.gravity = Gravity.CENTER_HORIZONTAL;
layoutParams.topMargin = AndroidUtilities.dp(20);
codeField.setLayoutParams(layoutParams);
codeField.setOnEditorActionListener(new TextView.OnEditorActionListener() { codeField.setOnEditorActionListener(new TextView.OnEditorActionListener() {
@Override @Override
public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) { public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) {
@ -1415,12 +1397,7 @@ public class LoginActivity extends BaseFragment {
cancelButton.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14); cancelButton.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14);
cancelButton.setLineSpacing(AndroidUtilities.dp(2), 1.0f); cancelButton.setLineSpacing(AndroidUtilities.dp(2), 1.0f);
cancelButton.setPadding(0, AndroidUtilities.dp(14), 0, 0); cancelButton.setPadding(0, AndroidUtilities.dp(14), 0, 0);
addView(cancelButton); addView(cancelButton, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, Gravity.TOP | (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT)));
layoutParams = (LayoutParams) cancelButton.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.gravity = Gravity.TOP | (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
cancelButton.setLayoutParams(layoutParams);
cancelButton.setOnClickListener(new OnClickListener() { cancelButton.setOnClickListener(new OnClickListener() {
@Override @Override
public void onClick(View view) { public void onClick(View view) {
@ -1488,13 +1465,7 @@ public class LoginActivity extends BaseFragment {
resetAccountButton.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14); resetAccountButton.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14);
resetAccountButton.setLineSpacing(AndroidUtilities.dp(2), 1.0f); resetAccountButton.setLineSpacing(AndroidUtilities.dp(2), 1.0f);
resetAccountButton.setPadding(0, AndroidUtilities.dp(14), 0, 0); resetAccountButton.setPadding(0, AndroidUtilities.dp(14), 0, 0);
addView(resetAccountButton); addView(resetAccountButton, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, Gravity.TOP | (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT), 0, 34, 0, 0));
layoutParams = (LayoutParams) resetAccountButton.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.gravity = Gravity.TOP | (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
layoutParams.topMargin = AndroidUtilities.dp(34);
resetAccountButton.setLayoutParams(layoutParams);
resetAccountButton.setOnClickListener(new OnClickListener() { resetAccountButton.setOnClickListener(new OnClickListener() {
@Override @Override
public void onClick(View view) { public void onClick(View view) {
@ -1541,14 +1512,7 @@ public class LoginActivity extends BaseFragment {
resetAccountText.setText(LocaleController.getString("ResetMyAccountText", R.string.ResetMyAccountText)); resetAccountText.setText(LocaleController.getString("ResetMyAccountText", R.string.ResetMyAccountText));
resetAccountText.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14); resetAccountText.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14);
resetAccountText.setLineSpacing(AndroidUtilities.dp(2), 1.0f); resetAccountText.setLineSpacing(AndroidUtilities.dp(2), 1.0f);
addView(resetAccountText); addView(resetAccountText, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, Gravity.TOP | (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT), 0, 7, 0, 14));
layoutParams = (LayoutParams) resetAccountText.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.gravity = Gravity.TOP | (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
layoutParams.bottomMargin = AndroidUtilities.dp(14);
layoutParams.topMargin = AndroidUtilities.dp(7);
resetAccountText.setLayoutParams(layoutParams);
} }
@Override @Override
@ -1740,12 +1704,7 @@ public class LoginActivity extends BaseFragment {
confirmTextView.setGravity((LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT)); confirmTextView.setGravity((LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT));
confirmTextView.setLineSpacing(AndroidUtilities.dp(2), 1.0f); confirmTextView.setLineSpacing(AndroidUtilities.dp(2), 1.0f);
confirmTextView.setText(LocaleController.getString("RestoreEmailSentInfo", R.string.RestoreEmailSentInfo)); confirmTextView.setText(LocaleController.getString("RestoreEmailSentInfo", R.string.RestoreEmailSentInfo));
addView(confirmTextView); addView(confirmTextView, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT)));
LayoutParams layoutParams = (LayoutParams) confirmTextView.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.gravity = (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
confirmTextView.setLayoutParams(layoutParams);
codeField = new EditText(context); codeField = new EditText(context);
codeField.setTextColor(0xff212121); codeField.setTextColor(0xff212121);
@ -1760,13 +1719,7 @@ public class LoginActivity extends BaseFragment {
codeField.setTransformationMethod(PasswordTransformationMethod.getInstance()); codeField.setTransformationMethod(PasswordTransformationMethod.getInstance());
codeField.setTypeface(Typeface.DEFAULT); codeField.setTypeface(Typeface.DEFAULT);
codeField.setGravity(LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT); codeField.setGravity(LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
addView(codeField); addView(codeField, LayoutHelper.createLinear(LayoutHelper.MATCH_PARENT, 36, Gravity.CENTER_HORIZONTAL, 0, 20, 0, 0));
layoutParams = (LayoutParams) codeField.getLayoutParams();
layoutParams.width = LayoutHelper.MATCH_PARENT;
layoutParams.height = AndroidUtilities.dp(36);
layoutParams.gravity = Gravity.CENTER_HORIZONTAL;
layoutParams.topMargin = AndroidUtilities.dp(20);
codeField.setLayoutParams(layoutParams);
codeField.setOnEditorActionListener(new TextView.OnEditorActionListener() { codeField.setOnEditorActionListener(new TextView.OnEditorActionListener() {
@Override @Override
public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) { public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) {
@ -1784,13 +1737,7 @@ public class LoginActivity extends BaseFragment {
cancelButton.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14); cancelButton.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14);
cancelButton.setLineSpacing(AndroidUtilities.dp(2), 1.0f); cancelButton.setLineSpacing(AndroidUtilities.dp(2), 1.0f);
cancelButton.setPadding(0, AndroidUtilities.dp(14), 0, 0); cancelButton.setPadding(0, AndroidUtilities.dp(14), 0, 0);
addView(cancelButton); addView(cancelButton, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, Gravity.BOTTOM | (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT), 0, 0, 0, 14));
layoutParams = (LayoutParams) cancelButton.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.gravity = Gravity.BOTTOM | (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
layoutParams.bottomMargin = AndroidUtilities.dp(14);
cancelButton.setLayoutParams(layoutParams);
cancelButton.setOnClickListener(new OnClickListener() { cancelButton.setOnClickListener(new OnClickListener() {
@Override @Override
public void onClick(View view) { public void onClick(View view) {
@ -1974,13 +1921,7 @@ public class LoginActivity extends BaseFragment {
textView.setTextColor(0xff757575); textView.setTextColor(0xff757575);
textView.setGravity(LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT); textView.setGravity(LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
textView.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14); textView.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14);
addView(textView); addView(textView, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT, 0, 8, 0, 0));
LayoutParams layoutParams = (LayoutParams) textView.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.topMargin = AndroidUtilities.dp(8);
layoutParams.gravity = LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT;
textView.setLayoutParams(layoutParams);
firstNameField = new EditText(context); firstNameField = new EditText(context);
firstNameField.setHintTextColor(0xff979797); firstNameField.setHintTextColor(0xff979797);
@ -1991,12 +1932,7 @@ public class LoginActivity extends BaseFragment {
firstNameField.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 18); firstNameField.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 18);
firstNameField.setMaxLines(1); firstNameField.setMaxLines(1);
firstNameField.setInputType(InputType.TYPE_TEXT_FLAG_CAP_WORDS); firstNameField.setInputType(InputType.TYPE_TEXT_FLAG_CAP_WORDS);
addView(firstNameField); addView(firstNameField, LayoutHelper.createLinear(LayoutHelper.MATCH_PARENT, 36, 0, 26, 0, 0));
layoutParams = (LayoutParams) firstNameField.getLayoutParams();
layoutParams.width = LayoutHelper.MATCH_PARENT;
layoutParams.height = AndroidUtilities.dp(36);
layoutParams.topMargin = AndroidUtilities.dp(26);
firstNameField.setLayoutParams(layoutParams);
firstNameField.setOnEditorActionListener(new TextView.OnEditorActionListener() { firstNameField.setOnEditorActionListener(new TextView.OnEditorActionListener() {
@Override @Override
public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) { public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) {
@ -2017,20 +1953,11 @@ public class LoginActivity extends BaseFragment {
lastNameField.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 18); lastNameField.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 18);
lastNameField.setMaxLines(1); lastNameField.setMaxLines(1);
lastNameField.setInputType(InputType.TYPE_TEXT_FLAG_CAP_WORDS); lastNameField.setInputType(InputType.TYPE_TEXT_FLAG_CAP_WORDS);
addView(lastNameField); addView(lastNameField, LayoutHelper.createLinear(LayoutHelper.MATCH_PARENT, 36, 0, 10, 0, 0));
layoutParams = (LayoutParams) lastNameField.getLayoutParams();
layoutParams.width = LayoutHelper.MATCH_PARENT;
layoutParams.height = AndroidUtilities.dp(36);
layoutParams.topMargin = AndroidUtilities.dp(10);
lastNameField.setLayoutParams(layoutParams);
LinearLayout linearLayout = new LinearLayout(context); LinearLayout linearLayout = new LinearLayout(context);
linearLayout.setGravity(Gravity.BOTTOM | Gravity.CENTER_VERTICAL); linearLayout.setGravity(Gravity.BOTTOM | Gravity.CENTER_VERTICAL);
addView(linearLayout); addView(linearLayout, LayoutHelper.createLinear(LayoutHelper.MATCH_PARENT, LayoutHelper.MATCH_PARENT));
layoutParams = (LayoutParams) linearLayout.getLayoutParams();
layoutParams.width = LayoutHelper.MATCH_PARENT;
layoutParams.height = LayoutHelper.MATCH_PARENT;
linearLayout.setLayoutParams(layoutParams);
TextView wrongNumber = new TextView(context); TextView wrongNumber = new TextView(context);
wrongNumber.setText(LocaleController.getString("CancelRegistration", R.string.CancelRegistration)); wrongNumber.setText(LocaleController.getString("CancelRegistration", R.string.CancelRegistration));
@ -2039,13 +1966,7 @@ public class LoginActivity extends BaseFragment {
wrongNumber.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14); wrongNumber.setTextSize(TypedValue.COMPLEX_UNIT_DIP, 14);
wrongNumber.setLineSpacing(AndroidUtilities.dp(2), 1.0f); wrongNumber.setLineSpacing(AndroidUtilities.dp(2), 1.0f);
wrongNumber.setPadding(0, AndroidUtilities.dp(24), 0, 0); wrongNumber.setPadding(0, AndroidUtilities.dp(24), 0, 0);
linearLayout.addView(wrongNumber); linearLayout.addView(wrongNumber, LayoutHelper.createLinear(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, Gravity.BOTTOM | (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT), 0, 0, 0, 10));
layoutParams = (LayoutParams) wrongNumber.getLayoutParams();
layoutParams.width = LayoutHelper.WRAP_CONTENT;
layoutParams.height = LayoutHelper.WRAP_CONTENT;
layoutParams.gravity = Gravity.BOTTOM | (LocaleController.isRTL ? Gravity.RIGHT : Gravity.LEFT);
layoutParams.bottomMargin = AndroidUtilities.dp(10);
wrongNumber.setLayoutParams(layoutParams);
wrongNumber.setOnClickListener(new OnClickListener() { wrongNumber.setOnClickListener(new OnClickListener() {
@Override @Override
public void onClick(View view) { public void onClick(View view) {

View File

@ -88,6 +88,7 @@ import java.util.HashMap;
import java.util.Timer; import java.util.Timer;
import java.util.TimerTask; import java.util.TimerTask;
@SuppressWarnings("unchecked")
public class MediaActivity extends BaseFragment implements NotificationCenter.NotificationCenterDelegate, PhotoViewer.PhotoViewerProvider { public class MediaActivity extends BaseFragment implements NotificationCenter.NotificationCenterDelegate, PhotoViewer.PhotoViewerProvider {
private SharedPhotoVideoAdapter photoVideoAdapter; private SharedPhotoVideoAdapter photoVideoAdapter;
@ -112,10 +113,12 @@ public class MediaActivity extends BaseFragment implements NotificationCenter.No
private boolean searchWas; private boolean searchWas;
private boolean searching; private boolean searching;
private HashMap<Integer, MessageObject> selectedFiles = new HashMap<>(); private HashMap<Integer, MessageObject>[] selectedFiles = new HashMap[] {new HashMap<>(), new HashMap<>()};
private int cantDeleteMessagesCount; private int cantDeleteMessagesCount;
private ArrayList<View> actionModeViews = new ArrayList<>(); private ArrayList<View> actionModeViews = new ArrayList<>();
private boolean scrolling; private boolean scrolling;
private long mergeDialogId;
protected TLRPC.ChatFull info = null;
private long dialog_id; private long dialog_id;
private int selectedMode; private int selectedMode;
@ -123,16 +126,17 @@ public class MediaActivity extends BaseFragment implements NotificationCenter.No
private class SharedMediaData { private class SharedMediaData {
private ArrayList<MessageObject> messages = new ArrayList<>(); private ArrayList<MessageObject> messages = new ArrayList<>();
private HashMap<Integer, MessageObject> messagesDict = new HashMap<>(); private HashMap<Integer, MessageObject>[] messagesDict = new HashMap[] {new HashMap<>(), new HashMap<>()};
private ArrayList<String> sections = new ArrayList<>(); private ArrayList<String> sections = new ArrayList<>();
private HashMap<String, ArrayList<MessageObject>> sectionArrays = new HashMap<>(); private HashMap<String, ArrayList<MessageObject>> sectionArrays = new HashMap<>();
private int totalCount; private int totalCount;
private boolean loading; private boolean loading;
private boolean endReached; private boolean endReached[] = new boolean[] {false, true};
private int max_id; private int max_id[] = new int[] {0, 0};
public boolean addMessage(MessageObject messageObject, boolean isNew, boolean enc) { public boolean addMessage(MessageObject messageObject, boolean isNew, boolean enc) {
if (messagesDict.containsKey(messageObject.getId())) { int loadIndex = messageObject.getDialogId() == dialog_id ? 0 : 1;
if (messagesDict[loadIndex].containsKey(messageObject.getId())) {
return false; return false;
} }
ArrayList<MessageObject> messageObjects = sectionArrays.get(messageObject.monthKey); ArrayList<MessageObject> messageObjects = sectionArrays.get(messageObject.monthKey);
@ -152,19 +156,19 @@ public class MediaActivity extends BaseFragment implements NotificationCenter.No
messageObjects.add(messageObject); messageObjects.add(messageObject);
messages.add(messageObject); messages.add(messageObject);
} }
messagesDict.put(messageObject.getId(), messageObject); messagesDict[loadIndex].put(messageObject.getId(), messageObject);
if (!enc) { if (!enc) {
if (messageObject.getId() > 0) { if (messageObject.getId() > 0) {
max_id = Math.min(messageObject.getId(), max_id); max_id[loadIndex] = Math.min(messageObject.getId(), max_id[loadIndex]);
} }
} else { } else {
max_id = Math.max(messageObject.getId(), max_id); max_id[loadIndex] = Math.max(messageObject.getId(), max_id[loadIndex]);
} }
return true; return true;
} }
public boolean deleteMessage(int mid) { public boolean deleteMessage(int mid, int loadIndex) {
MessageObject messageObject = messagesDict.get(mid); MessageObject messageObject = messagesDict[loadIndex].get(mid);
if (messageObject == null) { if (messageObject == null) {
return false; return false;
} }
@ -174,7 +178,7 @@ public class MediaActivity extends BaseFragment implements NotificationCenter.No
} }
messageObjects.remove(messageObject); messageObjects.remove(messageObject);
messages.remove(messageObject); messages.remove(messageObject);
messagesDict.remove(messageObject.getId()); messagesDict[loadIndex].remove(messageObject.getId());
if (messageObjects.isEmpty()) { if (messageObjects.isEmpty()) {
sectionArrays.remove(messageObject.monthKey); sectionArrays.remove(messageObject.monthKey);
sections.remove(messageObject.monthKey); sections.remove(messageObject.monthKey);
@ -184,10 +188,10 @@ public class MediaActivity extends BaseFragment implements NotificationCenter.No
} }
public void replaceMid(int oldMid, int newMid) { public void replaceMid(int oldMid, int newMid) {
MessageObject obj = messagesDict.get(oldMid); MessageObject obj = messagesDict[0].get(oldMid);
if (obj != null) { if (obj != null) {
messagesDict.remove(oldMid); messagesDict[0].remove(oldMid);
messagesDict.put(newMid, obj); messagesDict[0].put(newMid, obj);
obj.messageOwner.id = newMid; obj.messageOwner.id = newMid;
} }
} }
@ -218,7 +222,11 @@ private final static int quoteforward = 33;
dialog_id = getArguments().getLong("dialog_id", 0); dialog_id = getArguments().getLong("dialog_id", 0);
for (int a = 0; a < sharedMediaData.length; a++) { for (int a = 0; a < sharedMediaData.length; a++) {
sharedMediaData[a] = new SharedMediaData(); sharedMediaData[a] = new SharedMediaData();
sharedMediaData[a].max_id = ((int)dialog_id) == 0 ? Integer.MIN_VALUE : Integer.MAX_VALUE; sharedMediaData[a].max_id[0] = ((int)dialog_id) == 0 ? Integer.MIN_VALUE : Integer.MAX_VALUE;
if (mergeDialogId != 0 && info != null) {
sharedMediaData[a].max_id[1] = info.migrated_from_max_id;
sharedMediaData[a].endReached[1] = false;
}
} }
sharedMediaData[0].loading = true; sharedMediaData[0].loading = true;
SharedMediaQuery.loadMedia(dialog_id, 0, 50, 0, SharedMediaQuery.MEDIA_PHOTOVIDEO, true, classGuid); SharedMediaQuery.loadMedia(dialog_id, 0, 50, 0, SharedMediaQuery.MEDIA_PHOTOVIDEO, true, classGuid);
@ -248,7 +256,9 @@ private final static int quoteforward = 33;
public void onItemClick(int id) { public void onItemClick(int id) {
if (id == -1) { if (id == -1) {
if (actionBar.isActionModeShowed()) { if (actionBar.isActionModeShowed()) {
selectedFiles.clear(); for (int a = 1; a >= 0; a--) {
selectedFiles[a].clear();
}
cantDeleteMessagesCount = 0; cantDeleteMessagesCount = 0;
actionBar.hideActionMode(); actionBar.hideActionMode();
listView.invalidateViews(); listView.invalidateViews();
@ -292,17 +302,18 @@ private final static int quoteforward = 33;
return; return;
} }
AlertDialog.Builder builder = new AlertDialog.Builder(getParentActivity()); AlertDialog.Builder builder = new AlertDialog.Builder(getParentActivity());
builder.setMessage(LocaleController.formatString("AreYouSureDeleteMessages", R.string.AreYouSureDeleteMessages, LocaleController.formatPluralString("items", selectedFiles.size()))); builder.setMessage(LocaleController.formatString("AreYouSureDeleteMessages", R.string.AreYouSureDeleteMessages, LocaleController.formatPluralString("items", selectedFiles[0].size() + selectedFiles[1].size())));
builder.setTitle(LocaleController.getString("AppName", R.string.AppName)); builder.setTitle(LocaleController.getString("AppName", R.string.AppName));
builder.setPositiveButton(LocaleController.getString("OK", R.string.OK), new DialogInterface.OnClickListener() { builder.setPositiveButton(LocaleController.getString("OK", R.string.OK), new DialogInterface.OnClickListener() {
@Override @Override
public void onClick(DialogInterface dialogInterface, int i) { public void onClick(DialogInterface dialogInterface, int i) {
ArrayList<Integer> ids = new ArrayList<>(selectedFiles.keySet()); for (int a = 1; a >= 0; a--) {
ArrayList<Integer> ids = new ArrayList<>(selectedFiles[a].keySet());
ArrayList<Long> random_ids = null; ArrayList<Long> random_ids = null;
TLRPC.EncryptedChat currentEncryptedChat = null; TLRPC.EncryptedChat currentEncryptedChat = null;
int channelId = 0; int channelId = 0;
if (!ids.isEmpty()) { if (!ids.isEmpty()) {
MessageObject msg = selectedFiles.get(ids.get(0)); MessageObject msg = selectedFiles[a].get(ids.get(0));
if (channelId == 0 && msg.messageOwner.to_id.channel_id != 0) { if (channelId == 0 && msg.messageOwner.to_id.channel_id != 0) {
channelId = msg.messageOwner.to_id.channel_id; channelId = msg.messageOwner.to_id.channel_id;
} }
@ -312,7 +323,7 @@ private final static int quoteforward = 33;
} }
if (currentEncryptedChat != null) { if (currentEncryptedChat != null) {
random_ids = new ArrayList<>(); random_ids = new ArrayList<>();
for (HashMap.Entry<Integer, MessageObject> entry : selectedFiles.entrySet()) { for (HashMap.Entry<Integer, MessageObject> entry : selectedFiles[a].entrySet()) {
MessageObject msg = entry.getValue(); MessageObject msg = entry.getValue();
if (msg.messageOwner.random_id != 0 && msg.type != 10) { if (msg.messageOwner.random_id != 0 && msg.type != 10) {
random_ids.add(msg.messageOwner.random_id); random_ids.add(msg.messageOwner.random_id);
@ -320,9 +331,10 @@ private final static int quoteforward = 33;
} }
} }
MessagesController.getInstance().deleteMessages(ids, random_ids, currentEncryptedChat, channelId); MessagesController.getInstance().deleteMessages(ids, random_ids, currentEncryptedChat, channelId);
selectedFiles[a].clear();
}
actionBar.hideActionMode(); actionBar.hideActionMode();
actionBar.closeSearchField(); actionBar.closeSearchField();
selectedFiles.clear();
cantDeleteMessagesCount = 0; cantDeleteMessagesCount = 0;
} }
}); });
@ -351,14 +363,16 @@ private final static int quoteforward = 33;
} }
ArrayList<MessageObject> fmessages = new ArrayList<>(); ArrayList<MessageObject> fmessages = new ArrayList<>();
ArrayList<Integer> ids = new ArrayList<>(selectedFiles.keySet()); for (int a = 1; a >= 0; a--) {
ArrayList<Integer> ids = new ArrayList<>(selectedFiles[a].keySet());
Collections.sort(ids); Collections.sort(ids);
for (Integer id : ids) { for (Integer id : ids) {
if (id > 0) { if (id > 0) {
fmessages.add(selectedFiles.get(id)); fmessages.add(selectedFiles[a].get(id));
} }
} }
selectedFiles.clear(); selectedFiles[a].clear();
}
cantDeleteMessagesCount = 0; cantDeleteMessagesCount = 0;
actionBar.hideActionMode(); actionBar.hideActionMode();
@ -380,7 +394,9 @@ private final static int quoteforward = 33;
} }
}); });
selectedFiles.clear(); for (int a = 1; a >= 0; a--) {
selectedFiles[a].clear();
}
cantDeleteMessagesCount = 0; cantDeleteMessagesCount = 0;
actionModeViews.clear(); actionModeViews.clear();
@ -465,7 +481,6 @@ private final static int quoteforward = 33;
dropDownContainer.addView(dropDown, LayoutHelper.createFrame(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, Gravity.CENTER_VERTICAL, 16, 0, 0, 0)); dropDownContainer.addView(dropDown, LayoutHelper.createFrame(LayoutHelper.WRAP_CONTENT, LayoutHelper.WRAP_CONTENT, Gravity.CENTER_VERTICAL, 16, 0, 0, 0));
final ActionBarMenu actionMode = actionBar.createActionMode(); final ActionBarMenu actionMode = actionBar.createActionMode();
//actionModeViews.add(actionMode.addItem(-2, R.drawable.ic_ab_back_grey, R.drawable.bar_selector_mode, null, AndroidUtilities.dp(54)));
selectedMessagesCountTextView = new NumberTextView(actionMode.getContext()); selectedMessagesCountTextView = new NumberTextView(actionMode.getContext());
selectedMessagesCountTextView.setTextSize(18); selectedMessagesCountTextView.setTextSize(18);
@ -526,8 +541,7 @@ private final static int quoteforward = 33;
if (searching && searchWas) { if (searching && searchWas) {
return; return;
} }
if (visibleItemCount != 0 && firstVisibleItem + visibleItemCount > totalItemCount - 2 && !sharedMediaData[selectedMode].loading && !sharedMediaData[selectedMode].endReached) { if (visibleItemCount != 0 && firstVisibleItem + visibleItemCount > totalItemCount - 2 && !sharedMediaData[selectedMode].loading) {
sharedMediaData[selectedMode].loading = true;
int type; int type;
if (selectedMode == 0) { if (selectedMode == 0) {
type = SharedMediaQuery.MEDIA_PHOTOVIDEO; type = SharedMediaQuery.MEDIA_PHOTOVIDEO;
@ -540,7 +554,13 @@ private final static int quoteforward = 33;
} else { } else {
type = SharedMediaQuery.MEDIA_URL; type = SharedMediaQuery.MEDIA_URL;
} }
SharedMediaQuery.loadMedia(dialog_id, 0, 50, sharedMediaData[selectedMode].max_id, type, true, classGuid); if (!sharedMediaData[selectedMode].endReached[0]) {
sharedMediaData[selectedMode].loading = true;
SharedMediaQuery.loadMedia(dialog_id, 0, 50, sharedMediaData[selectedMode].max_id[0], type, true, classGuid);
} else if (mergeDialogId != 0 && !sharedMediaData[selectedMode].endReached[1]) {
sharedMediaData[selectedMode].loading = true;
SharedMediaQuery.loadMedia(mergeDialogId, 0, 50, sharedMediaData[selectedMode].max_id[1], type, true, classGuid);
}
} }
} }
}); });
@ -606,22 +626,28 @@ private final static int quoteforward = 33;
return fragmentView; return fragmentView;
} }
@SuppressWarnings("unchecked")
@Override @Override
public void didReceivedNotification(int id, Object... args) { public void didReceivedNotification(int id, Object... args) {
if (id == NotificationCenter.mediaDidLoaded) { if (id == NotificationCenter.mediaDidLoaded) {
long uid = (Long) args[0]; long uid = (Long) args[0];
int guid = (Integer) args[3]; int guid = (Integer) args[3];
if (uid == dialog_id && guid == classGuid) { if (guid == classGuid) {
int type = (Integer) args[4]; int type = (Integer) args[4];
sharedMediaData[type].loading = false; sharedMediaData[type].loading = false;
sharedMediaData[type].totalCount = (Integer) args[1]; sharedMediaData[type].totalCount = (Integer) args[1];
ArrayList<MessageObject> arr = (ArrayList<MessageObject>) args[2]; ArrayList<MessageObject> arr = (ArrayList<MessageObject>) args[2];
boolean enc = ((int) dialog_id) == 0; boolean enc = ((int) dialog_id) == 0;
for (MessageObject message : arr) { int loadIndex = uid == dialog_id ? 0 : 1;
for (int a = 0; a < arr.size(); a++) {
MessageObject message = arr.get(a);
sharedMediaData[type].addMessage(message, false, enc); sharedMediaData[type].addMessage(message, false, enc);
} }
sharedMediaData[type].endReached = (Boolean) args[5]; sharedMediaData[type].endReached[loadIndex] = (Boolean) args[5];
if (loadIndex == 0 && sharedMediaData[selectedMode].messages.isEmpty() && mergeDialogId != 0) {
sharedMediaData[selectedMode].loading = true;
SharedMediaQuery.loadMedia(mergeDialogId, 0, 50, sharedMediaData[selectedMode].max_id[1], type, true, classGuid);
}
if (!sharedMediaData[selectedMode].loading) {
if (progressView != null) { if (progressView != null) {
progressView.setVisibility(View.GONE); progressView.setVisibility(View.GONE);
} }
@ -630,6 +656,7 @@ private final static int quoteforward = 33;
listView.setEmptyView(emptyView); listView.setEmptyView(emptyView);
} }
} }
}
scrolling = true; scrolling = true;
if (selectedMode == 0 && type == 0) { if (selectedMode == 0 && type == 0) {
if (photoVideoAdapter != null) { if (photoVideoAdapter != null) {
@ -658,8 +685,13 @@ private final static int quoteforward = 33;
currentChat = MessagesController.getInstance().getChat(-(int) dialog_id); currentChat = MessagesController.getInstance().getChat(-(int) dialog_id);
} }
int channelId = (Integer) args[1]; int channelId = (Integer) args[1];
int loadIndex = 0;
if (ChatObject.isChannel(currentChat)) { if (ChatObject.isChannel(currentChat)) {
if (channelId == 0 || channelId != currentChat.id) { if (channelId == 0 && mergeDialogId != 0) {
loadIndex = 1;
} else if (channelId == currentChat.id) {
loadIndex = 0;
} else {
return; return;
} }
} else if (channelId != 0) { } else if (channelId != 0) {
@ -669,7 +701,7 @@ private final static int quoteforward = 33;
boolean updated = false; boolean updated = false;
for (Integer ids : markAsDeletedMessages) { for (Integer ids : markAsDeletedMessages) {
for (SharedMediaData data : sharedMediaData) { for (SharedMediaData data : sharedMediaData) {
if (data.deleteMessage(ids)) { if (data.deleteMessage(ids, loadIndex)) {
updated = true; updated = true;
} }
} }
@ -809,6 +841,8 @@ private final static int quoteforward = 33;
object.parentView = listView; object.parentView = listView;
object.imageReceiver = imageView.getImageReceiver(); object.imageReceiver = imageView.getImageReceiver();
object.thumb = object.imageReceiver.getBitmap(); object.thumb = object.imageReceiver.getBitmap();
object.parentView.getLocationInWindow(coords);
object.clipTopAddition = AndroidUtilities.dp(40);
return object; return object;
} }
} }
@ -843,6 +877,13 @@ private final static int quoteforward = 33;
@Override @Override
public int getSelectedCount() { return 0; } public int getSelectedCount() { return 0; }
public void setChatInfo(TLRPC.ChatFull chatInfo) {
info = chatInfo;
if (info != null && info.migrated_from_chat_id != 0) {
mergeDialogId = -info.migrated_from_chat_id;
}
}
private void switchToCurrentSelectedMode() { private void switchToCurrentSelectedMode() {
if (searching && searchWas) { if (searching && searchWas) {
if (listView != null) { if (listView != null) {
@ -894,7 +935,7 @@ private final static int quoteforward = 33;
emptyTextView.setText(LocaleController.getString("NoSharedAudio", R.string.NoSharedAudio)); emptyTextView.setText(LocaleController.getString("NoSharedAudio", R.string.NoSharedAudio));
} }
searchItem.setVisibility(!sharedMediaData[selectedMode].messages.isEmpty() ? View.VISIBLE : View.GONE); searchItem.setVisibility(!sharedMediaData[selectedMode].messages.isEmpty() ? View.VISIBLE : View.GONE);
if (!sharedMediaData[selectedMode].loading && !sharedMediaData[selectedMode].endReached && sharedMediaData[selectedMode].messages.isEmpty()) { if (!sharedMediaData[selectedMode].loading && !sharedMediaData[selectedMode].endReached[0] && sharedMediaData[selectedMode].messages.isEmpty()) {
sharedMediaData[selectedMode].loading = true; sharedMediaData[selectedMode].loading = true;
SharedMediaQuery.loadMedia(dialog_id, 0, 50, 0, selectedMode == 1 ? SharedMediaQuery.MEDIA_FILE : SharedMediaQuery.MEDIA_MUSIC, true, classGuid); SharedMediaQuery.loadMedia(dialog_id, 0, 50, 0, selectedMode == 1 ? SharedMediaQuery.MEDIA_FILE : SharedMediaQuery.MEDIA_MUSIC, true, classGuid);
} }
@ -914,7 +955,7 @@ private final static int quoteforward = 33;
emptyImageView.setImageResource(R.drawable.tip3); emptyImageView.setImageResource(R.drawable.tip3);
emptyTextView.setText(LocaleController.getString("NoSharedLinks", R.string.NoSharedLinks)); emptyTextView.setText(LocaleController.getString("NoSharedLinks", R.string.NoSharedLinks));
searchItem.setVisibility(!sharedMediaData[3].messages.isEmpty() ? View.VISIBLE : View.GONE); searchItem.setVisibility(!sharedMediaData[3].messages.isEmpty() ? View.VISIBLE : View.GONE);
if (!sharedMediaData[selectedMode].loading && !sharedMediaData[selectedMode].endReached && sharedMediaData[selectedMode].messages.isEmpty()) { if (!sharedMediaData[selectedMode].loading && !sharedMediaData[selectedMode].endReached[0] && sharedMediaData[selectedMode].messages.isEmpty()) {
sharedMediaData[selectedMode].loading = true; sharedMediaData[selectedMode].loading = true;
SharedMediaQuery.loadMedia(dialog_id, 0, 50, 0, SharedMediaQuery.MEDIA_URL, true, classGuid); SharedMediaQuery.loadMedia(dialog_id, 0, 50, 0, SharedMediaQuery.MEDIA_URL, true, classGuid);
} }
@ -936,7 +977,8 @@ private final static int quoteforward = 33;
if (actionBar.isActionModeShowed()) { if (actionBar.isActionModeShowed()) {
return false; return false;
} }
selectedFiles.put(item.getId(), item); AndroidUtilities.hideKeyboard(getParentActivity().getCurrentFocus());
selectedFiles[item.getDialogId() == dialog_id ? 0 : 1].put(item.getId(), item);
if (!item.canDeleteMessage(null)) { if (!item.canDeleteMessage(null)) {
cantDeleteMessagesCount++; cantDeleteMessagesCount++;
} }
@ -971,35 +1013,36 @@ private final static int quoteforward = 33;
return; return;
} }
if (actionBar.isActionModeShowed()) { if (actionBar.isActionModeShowed()) {
if (selectedFiles.containsKey(message.getId())) { int loadIndex = message.getDialogId() == dialog_id ? 0 : 1;
selectedFiles.remove(message.getId()); if (selectedFiles[loadIndex].containsKey(message.getId())) {
selectedFiles[loadIndex].remove(message.getId());
if (!message.canDeleteMessage(null)) { if (!message.canDeleteMessage(null)) {
cantDeleteMessagesCount--; cantDeleteMessagesCount--;
} }
} else { } else {
selectedFiles.put(message.getId(), message); selectedFiles[loadIndex].put(message.getId(), message);
if (!message.canDeleteMessage(null)) { if (!message.canDeleteMessage(null)) {
cantDeleteMessagesCount++; cantDeleteMessagesCount++;
} }
} }
if (selectedFiles.isEmpty()) { if (selectedFiles[0].isEmpty() && selectedFiles[1].isEmpty()) {
actionBar.hideActionMode(); actionBar.hideActionMode();
} else { } else {
selectedMessagesCountTextView.setNumber(selectedFiles.size(), true); selectedMessagesCountTextView.setNumber(selectedFiles[0].size() + selectedFiles[1].size(), true);
} }
actionBar.createActionMode().getItem(delete).setVisibility(cantDeleteMessagesCount == 0 ? View.VISIBLE : View.GONE); actionBar.createActionMode().getItem(delete).setVisibility(cantDeleteMessagesCount == 0 ? View.VISIBLE : View.GONE);
scrolling = false; scrolling = false;
if (view instanceof SharedDocumentCell) { if (view instanceof SharedDocumentCell) {
((SharedDocumentCell) view).setChecked(selectedFiles.containsKey(message.getId()), true); ((SharedDocumentCell) view).setChecked(selectedFiles[loadIndex].containsKey(message.getId()), true);
} else if (view instanceof SharedPhotoVideoCell) { } else if (view instanceof SharedPhotoVideoCell) {
((SharedPhotoVideoCell) view).setChecked(a, selectedFiles.containsKey(message.getId()), true); ((SharedPhotoVideoCell) view).setChecked(a, selectedFiles[loadIndex].containsKey(message.getId()), true);
} else if (view instanceof SharedLinkCell) { } else if (view instanceof SharedLinkCell) {
((SharedLinkCell) view).setChecked(selectedFiles.containsKey(message.getId()), true); ((SharedLinkCell) view).setChecked(selectedFiles[loadIndex].containsKey(message.getId()), true);
} }
} else { } else {
if (selectedMode == 0) { if (selectedMode == 0) {
PhotoViewer.getInstance().setParentActivity(getParentActivity()); PhotoViewer.getInstance().setParentActivity(getParentActivity());
PhotoViewer.getInstance().openPhoto(sharedMediaData[selectedMode].messages, index, this); PhotoViewer.getInstance().openPhoto(sharedMediaData[selectedMode].messages, index, dialog_id, mergeDialogId, this);
} else if (selectedMode == 1 || selectedMode == 4) { } else if (selectedMode == 1 || selectedMode == 4) {
if (view instanceof SharedDocumentCell) { if (view instanceof SharedDocumentCell) {
SharedDocumentCell cell = (SharedDocumentCell) view; SharedDocumentCell cell = (SharedDocumentCell) view;
@ -1165,7 +1208,7 @@ private final static int quoteforward = 33;
@Override @Override
public int getSectionCount() { public int getSectionCount() {
return sharedMediaData[3].sections.size() + (sharedMediaData[3].sections.isEmpty() || sharedMediaData[3].endReached ? 0 : 1); return sharedMediaData[3].sections.size() + (sharedMediaData[3].sections.isEmpty() || sharedMediaData[3].endReached[0] && sharedMediaData[3].endReached[1] ? 0 : 1);
} }
@Override @Override
@ -1185,7 +1228,7 @@ private final static int quoteforward = 33;
String name = sharedMediaData[3].sections.get(section); String name = sharedMediaData[3].sections.get(section);
ArrayList<MessageObject> messageObjects = sharedMediaData[3].sectionArrays.get(name); ArrayList<MessageObject> messageObjects = sharedMediaData[3].sectionArrays.get(name);
MessageObject messageObject = messageObjects.get(0); MessageObject messageObject = messageObjects.get(0);
((GreySectionCell) convertView).setText(LocaleController.formatterMonthYear.format((long) messageObject.messageOwner.date * 1000).toUpperCase()); ((GreySectionCell) convertView).setText(LocaleController.getInstance().formatterMonthYear.format((long) messageObject.messageOwner.date * 1000).toUpperCase());
} }
return convertView; return convertView;
} }
@ -1200,7 +1243,7 @@ private final static int quoteforward = 33;
convertView = new GreySectionCell(mContext); convertView = new GreySectionCell(mContext);
} }
MessageObject messageObject = messageObjects.get(0); MessageObject messageObject = messageObjects.get(0);
((GreySectionCell) convertView).setText(LocaleController.formatterMonthYear.format((long) messageObject.messageOwner.date * 1000).toUpperCase()); ((GreySectionCell) convertView).setText(LocaleController.getInstance().formatterMonthYear.format((long) messageObject.messageOwner.date * 1000).toUpperCase());
} else { } else {
if (convertView == null) { if (convertView == null) {
convertView = new SharedLinkCell(mContext); convertView = new SharedLinkCell(mContext);
@ -1220,7 +1263,7 @@ private final static int quoteforward = 33;
MessageObject messageObject = messageObjects.get(position - 1); MessageObject messageObject = messageObjects.get(position - 1);
sharedLinkCell.setLink(messageObject, position != messageObjects.size() || section == sharedMediaData[3].sections.size() - 1 && sharedMediaData[3].loading); sharedLinkCell.setLink(messageObject, position != messageObjects.size() || section == sharedMediaData[3].sections.size() - 1 && sharedMediaData[3].loading);
if (actionBar.isActionModeShowed()) { if (actionBar.isActionModeShowed()) {
sharedLinkCell.setChecked(selectedFiles.containsKey(messageObject.getId()), !scrolling); sharedLinkCell.setChecked(selectedFiles[messageObject.getDialogId() == dialog_id ? 0 : 1].containsKey(messageObject.getId()), !scrolling);
} else { } else {
sharedLinkCell.setChecked(false, !scrolling); sharedLinkCell.setChecked(false, !scrolling);
} }
@ -1273,7 +1316,7 @@ private final static int quoteforward = 33;
@Override @Override
public int getSectionCount() { public int getSectionCount() {
return sharedMediaData[currentType].sections.size() + (sharedMediaData[currentType].sections.isEmpty() || sharedMediaData[currentType].endReached ? 0 : 1); return sharedMediaData[currentType].sections.size() + (sharedMediaData[currentType].sections.isEmpty() || sharedMediaData[currentType].endReached[0] && sharedMediaData[currentType].endReached[1] ? 0 : 1);
} }
@Override @Override
@ -1293,7 +1336,7 @@ private final static int quoteforward = 33;
String name = sharedMediaData[currentType].sections.get(section); String name = sharedMediaData[currentType].sections.get(section);
ArrayList<MessageObject> messageObjects = sharedMediaData[currentType].sectionArrays.get(name); ArrayList<MessageObject> messageObjects = sharedMediaData[currentType].sectionArrays.get(name);
MessageObject messageObject = messageObjects.get(0); MessageObject messageObject = messageObjects.get(0);
((GreySectionCell) convertView).setText(LocaleController.formatterMonthYear.format((long) messageObject.messageOwner.date * 1000).toUpperCase()); ((GreySectionCell) convertView).setText(LocaleController.getInstance().formatterMonthYear.format((long) messageObject.messageOwner.date * 1000).toUpperCase());
} }
return convertView; return convertView;
} }
@ -1308,7 +1351,7 @@ private final static int quoteforward = 33;
convertView = new GreySectionCell(mContext); convertView = new GreySectionCell(mContext);
} }
MessageObject messageObject = messageObjects.get(0); MessageObject messageObject = messageObjects.get(0);
((GreySectionCell) convertView).setText(LocaleController.formatterMonthYear.format((long) messageObject.messageOwner.date * 1000).toUpperCase()); ((GreySectionCell) convertView).setText(LocaleController.getInstance().formatterMonthYear.format((long) messageObject.messageOwner.date * 1000).toUpperCase());
} else { } else {
if (convertView == null) { if (convertView == null) {
convertView = new SharedDocumentCell(mContext); convertView = new SharedDocumentCell(mContext);
@ -1317,7 +1360,7 @@ private final static int quoteforward = 33;
MessageObject messageObject = messageObjects.get(position - 1); MessageObject messageObject = messageObjects.get(position - 1);
sharedDocumentCell.setDocument(messageObject, position != messageObjects.size() || section == sharedMediaData[currentType].sections.size() - 1 && sharedMediaData[currentType].loading); sharedDocumentCell.setDocument(messageObject, position != messageObjects.size() || section == sharedMediaData[currentType].sections.size() - 1 && sharedMediaData[currentType].loading);
if (actionBar.isActionModeShowed()) { if (actionBar.isActionModeShowed()) {
sharedDocumentCell.setChecked(selectedFiles.containsKey(messageObject.getId()), !scrolling); sharedDocumentCell.setChecked(selectedFiles[messageObject.getDialogId() == dialog_id ? 0 : 1].containsKey(messageObject.getId()), !scrolling);
} else { } else {
sharedDocumentCell.setChecked(false, !scrolling); sharedDocumentCell.setChecked(false, !scrolling);
} }
@ -1367,7 +1410,7 @@ private final static int quoteforward = 33;
@Override @Override
public int getSectionCount() { public int getSectionCount() {
return sharedMediaData[0].sections.size() + (sharedMediaData[0].sections.isEmpty() || sharedMediaData[0].endReached ? 0 : 1); return sharedMediaData[0].sections.size() + (sharedMediaData[0].sections.isEmpty() || sharedMediaData[0].endReached[0] && sharedMediaData[0].endReached[1] ? 0 : 1);
} }
@Override @Override
@ -1388,7 +1431,7 @@ private final static int quoteforward = 33;
String name = sharedMediaData[0].sections.get(section); String name = sharedMediaData[0].sections.get(section);
ArrayList<MessageObject> messageObjects = sharedMediaData[0].sectionArrays.get(name); ArrayList<MessageObject> messageObjects = sharedMediaData[0].sectionArrays.get(name);
MessageObject messageObject = messageObjects.get(0); MessageObject messageObject = messageObjects.get(0);
((SharedMediaSectionCell) convertView).setText(LocaleController.formatterMonthYear.format((long) messageObject.messageOwner.date * 1000).toUpperCase()); ((SharedMediaSectionCell) convertView).setText(LocaleController.getInstance().formatterMonthYear.format((long) messageObject.messageOwner.date * 1000).toUpperCase());
} }
return convertView; return convertView;
} }
@ -1403,7 +1446,7 @@ private final static int quoteforward = 33;
convertView = new SharedMediaSectionCell(mContext); convertView = new SharedMediaSectionCell(mContext);
} }
MessageObject messageObject = messageObjects.get(0); MessageObject messageObject = messageObjects.get(0);
((SharedMediaSectionCell) convertView).setText(LocaleController.formatterMonthYear.format((long) messageObject.messageOwner.date * 1000).toUpperCase()); ((SharedMediaSectionCell) convertView).setText(LocaleController.getInstance().formatterMonthYear.format((long) messageObject.messageOwner.date * 1000).toUpperCase());
} else { } else {
SharedPhotoVideoCell cell; SharedPhotoVideoCell cell;
if (convertView == null) { if (convertView == null) {
@ -1437,7 +1480,7 @@ private final static int quoteforward = 33;
cell.setItem(a, sharedMediaData[0].messages.indexOf(messageObject), messageObject); cell.setItem(a, sharedMediaData[0].messages.indexOf(messageObject), messageObject);
if (actionBar.isActionModeShowed()) { if (actionBar.isActionModeShowed()) {
cell.setChecked(a, selectedFiles.containsKey(messageObject.getId()), !scrolling); cell.setChecked(a, selectedFiles[messageObject.getDialogId() == dialog_id ? 0 : 1].containsKey(messageObject.getId()), !scrolling);
} else { } else {
cell.setChecked(a, false, !scrolling); cell.setChecked(a, false, !scrolling);
} }
@ -1487,8 +1530,8 @@ private final static int quoteforward = 33;
currentType = type; currentType = type;
} }
public void queryServerSearch(final String query, final int max_id) { public void queryServerSearch(final String query, final int max_id, long did) {
int uid = (int) dialog_id; int uid = (int) did;
if (uid == 0) { if (uid == 0) {
return; return;
} }
@ -1525,7 +1568,11 @@ private final static int quoteforward = 33;
final ArrayList<MessageObject> messageObjects = new ArrayList<>(); final ArrayList<MessageObject> messageObjects = new ArrayList<>();
if (error == null) { if (error == null) {
TLRPC.messages_Messages res = (TLRPC.messages_Messages) response; TLRPC.messages_Messages res = (TLRPC.messages_Messages) response;
for (TLRPC.Message message : res.messages) { for (int a = 0; a < res.messages.size(); a++) {
TLRPC.Message message = res.messages.get(a);
if (message.id > max_id) {
continue;
}
messageObjects.add(new MessageObject(message, null, false)); messageObjects.add(new MessageObject(message, null, false));
} }
} }
@ -1577,14 +1624,14 @@ private final static int quoteforward = 33;
@Override @Override
public void run() { public void run() {
if (!sharedMediaData[currentType].messages.isEmpty()) { if (!sharedMediaData[currentType].messages.isEmpty()) {
if (currentType == 1 || currentType == 4) { if (currentType == 1) {
MessageObject messageObject = sharedMediaData[currentType].messages.get(sharedMediaData[currentType].messages.size() - 1); MessageObject messageObject = sharedMediaData[currentType].messages.get(sharedMediaData[currentType].messages.size() - 1);
queryServerSearch(query, messageObject.getId()); queryServerSearch(query, messageObject.getId(), messageObject.getDialogId());
} else if (currentType == 3) { } else if (currentType == 3 || currentType == 4) {
queryServerSearch(query, 0); queryServerSearch(query, 0, dialog_id);
} }
} }
if (currentType == 1 || currentType == 4) { if (currentType == 1) {
final ArrayList<MessageObject> copy = new ArrayList<>(); final ArrayList<MessageObject> copy = new ArrayList<>();
copy.addAll(sharedMediaData[currentType].messages); copy.addAll(sharedMediaData[currentType].messages);
Utilities.searchQueue.postRunnable(new Runnable() { Utilities.searchQueue.postRunnable(new Runnable() {
@ -1607,7 +1654,8 @@ private final static int quoteforward = 33;
ArrayList<MessageObject> resultArray = new ArrayList<>(); ArrayList<MessageObject> resultArray = new ArrayList<>();
for (MessageObject messageObject : copy) { for (int a = 0; a < copy.size(); a++) {
MessageObject messageObject = copy.get(a);
for (String q : search) { for (String q : search) {
String name = messageObject.getDocumentName(); String name = messageObject.getDocumentName();
if (name == null || name.length() == 0) { if (name == null || name.length() == 0) {
@ -1699,7 +1747,7 @@ private final static int quoteforward = 33;
MessageObject messageObject = getItem(i); MessageObject messageObject = getItem(i);
sharedDocumentCell.setDocument(messageObject, i != getCount() - 1); sharedDocumentCell.setDocument(messageObject, i != getCount() - 1);
if (actionBar.isActionModeShowed()) { if (actionBar.isActionModeShowed()) {
sharedDocumentCell.setChecked(selectedFiles.containsKey(messageObject.getId()), !scrolling); sharedDocumentCell.setChecked(selectedFiles[messageObject.getDialogId() == dialog_id ? 0 : 1].containsKey(messageObject.getId()), !scrolling);
} else { } else {
sharedDocumentCell.setChecked(false, !scrolling); sharedDocumentCell.setChecked(false, !scrolling);
} }
@ -1722,7 +1770,7 @@ private final static int quoteforward = 33;
MessageObject messageObject = getItem(i); MessageObject messageObject = getItem(i);
sharedLinkCell.setLink(messageObject, i != getCount() - 1); sharedLinkCell.setLink(messageObject, i != getCount() - 1);
if (actionBar.isActionModeShowed()) { if (actionBar.isActionModeShowed()) {
sharedLinkCell.setChecked(selectedFiles.containsKey(messageObject.getId()), !scrolling); sharedLinkCell.setChecked(selectedFiles[messageObject.getDialogId() == dialog_id ? 0 : 1].containsKey(messageObject.getId()), !scrolling);
} else { } else {
sharedLinkCell.setChecked(false, !scrolling); sharedLinkCell.setChecked(false, !scrolling);
} }

View File

@ -52,40 +52,40 @@ import android.widget.Scroller;
import android.widget.TextView; import android.widget.TextView;
import org.telegram.messenger.AndroidUtilities; import org.telegram.messenger.AndroidUtilities;
import org.telegram.messenger.ImageLoader;
import org.telegram.messenger.MessagesStorage;
import org.telegram.messenger.UserObject;
import org.telegram.messenger.query.SharedMediaQuery;
import org.telegram.messenger.ApplicationLoader;
import org.telegram.messenger.FileLoader;
import org.telegram.messenger.FileLog;
import org.telegram.messenger.LocaleController;
import org.telegram.messenger.MediaController;
import org.telegram.messenger.MessagesController;
import org.telegram.messenger.NotificationCenter;
import org.telegram.messenger.R;
import org.telegram.tgnet.ConnectionsManager;
import org.telegram.tgnet.TLRPC;
import org.telegram.messenger.UserConfig;
import org.telegram.messenger.MessageObject;
import org.telegram.messenger.Utilities;
import org.telegram.ui.Adapters.MentionsAdapter;
import org.telegram.messenger.AnimationCompat.AnimatorListenerAdapterProxy; import org.telegram.messenger.AnimationCompat.AnimatorListenerAdapterProxy;
import org.telegram.messenger.AnimationCompat.AnimatorSetProxy; import org.telegram.messenger.AnimationCompat.AnimatorSetProxy;
import org.telegram.messenger.AnimationCompat.ObjectAnimatorProxy; import org.telegram.messenger.AnimationCompat.ObjectAnimatorProxy;
import org.telegram.messenger.AnimationCompat.ViewProxy; import org.telegram.messenger.AnimationCompat.ViewProxy;
import org.telegram.messenger.ApplicationLoader;
import org.telegram.messenger.FileLoader;
import org.telegram.messenger.FileLog;
import org.telegram.messenger.ImageLoader;
import org.telegram.messenger.ImageReceiver;
import org.telegram.messenger.LocaleController;
import org.telegram.messenger.MediaController;
import org.telegram.messenger.MessageObject;
import org.telegram.messenger.MessagesController;
import org.telegram.messenger.MessagesStorage;
import org.telegram.messenger.NotificationCenter;
import org.telegram.messenger.R;
import org.telegram.messenger.UserConfig;
import org.telegram.messenger.UserObject;
import org.telegram.messenger.Utilities;
import org.telegram.messenger.query.SharedMediaQuery;
import org.telegram.tgnet.ConnectionsManager;
import org.telegram.tgnet.TLRPC;
import org.telegram.ui.ActionBar.ActionBar; import org.telegram.ui.ActionBar.ActionBar;
import org.telegram.ui.ActionBar.ActionBarMenu; import org.telegram.ui.ActionBar.ActionBarMenu;
import org.telegram.ui.ActionBar.ActionBarMenuItem; import org.telegram.ui.ActionBar.ActionBarMenuItem;
import org.telegram.ui.Adapters.MentionsAdapter;
import org.telegram.ui.Components.CheckBox; import org.telegram.ui.Components.CheckBox;
import org.telegram.ui.Components.ClippingImageView; import org.telegram.ui.Components.ClippingImageView;
import org.telegram.messenger.ImageReceiver;
import org.telegram.ui.Components.GifDrawable; import org.telegram.ui.Components.GifDrawable;
import org.telegram.ui.Components.LayoutHelper; import org.telegram.ui.Components.LayoutHelper;
import org.telegram.ui.Components.PhotoCropView; import org.telegram.ui.Components.PhotoCropView;
import org.telegram.ui.Components.PhotoFilterView; import org.telegram.ui.Components.PhotoFilterView;
import org.telegram.ui.Components.PickerBottomLayout;
import org.telegram.ui.Components.PhotoViewerCaptionEnterView; import org.telegram.ui.Components.PhotoViewerCaptionEnterView;
import org.telegram.ui.Components.PickerBottomLayout;
import org.telegram.ui.Components.SizeNotifierFrameLayoutPhoto; import org.telegram.ui.Components.SizeNotifierFrameLayoutPhoto;
import java.io.File; import java.io.File;
@ -96,6 +96,7 @@ import java.util.Date;
import java.util.HashMap; import java.util.HashMap;
import java.util.Locale; import java.util.Locale;
@SuppressWarnings("unchecked")
public class PhotoViewer implements NotificationCenter.NotificationCenterDelegate, GestureDetector.OnGestureListener, GestureDetector.OnDoubleTapListener { public class PhotoViewer implements NotificationCenter.NotificationCenterDelegate, GestureDetector.OnGestureListener, GestureDetector.OnDoubleTapListener {
private int classGuid; private int classGuid;
@ -172,11 +173,13 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
private int avatarsUserId; private int avatarsUserId;
private long currentDialogId; private long currentDialogId;
private long mergeDialogId;
private int totalImagesCount; private int totalImagesCount;
private int totalImagesCountMerge;
private boolean isFirstLoading; private boolean isFirstLoading;
private boolean needSearchImageInArr; private boolean needSearchImageInArr;
private boolean loadingMoreImages; private boolean loadingMoreImages;
private boolean endReached; private boolean endReached[] = new boolean[] {false, true};
private boolean opennedFromMedia; private boolean opennedFromMedia;
private boolean draggingDown = false; private boolean draggingDown = false;
@ -219,9 +222,9 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
private Scroller scroller = null; private Scroller scroller = null;
private ArrayList<MessageObject> imagesArrTemp = new ArrayList<>(); private ArrayList<MessageObject> imagesArrTemp = new ArrayList<>();
private HashMap<Integer, MessageObject> imagesByIdsTemp = new HashMap<>(); private HashMap<Integer, MessageObject>[] imagesByIdsTemp = new HashMap[] {new HashMap<>(), new HashMap<>()};
private ArrayList<MessageObject> imagesArr = new ArrayList<>(); private ArrayList<MessageObject> imagesArr = new ArrayList<>();
private HashMap<Integer, MessageObject> imagesByIds = new HashMap<>(); private HashMap<Integer, MessageObject>[] imagesByIds = new HashMap[] {new HashMap<>(), new HashMap<>()};
private ArrayList<TLRPC.FileLocation> imagesArrLocations = new ArrayList<>(); private ArrayList<TLRPC.FileLocation> imagesArrLocations = new ArrayList<>();
private ArrayList<TLRPC.Photo> avatarsArr = new ArrayList<>(); private ArrayList<TLRPC.Photo> avatarsArr = new ArrayList<>();
private ArrayList<Integer> imagesArrLocationsSizes = new ArrayList<>(); private ArrayList<Integer> imagesArrLocationsSizes = new ArrayList<>();
@ -412,6 +415,7 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
public int size; public int size;
public int radius; public int radius;
public int clipBottomAddition; public int clipBottomAddition;
public int clipTopAddition;
public float scale = 1.0f; public float scale = 1.0f;
} }
@ -532,6 +536,9 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
int widthSize = MeasureSpec.getSize(widthMeasureSpec); int widthSize = MeasureSpec.getSize(widthMeasureSpec);
int heightSize = MeasureSpec.getSize(heightMeasureSpec); int heightSize = MeasureSpec.getSize(heightMeasureSpec);
if (heightSize > AndroidUtilities.displaySize.y - AndroidUtilities.statusBarHeight) {
heightSize = AndroidUtilities.displaySize.y - AndroidUtilities.statusBarHeight;
}
setMeasuredDimension(widthSize, heightSize); setMeasuredDimension(widthSize, heightSize);
@ -732,32 +739,40 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
} }
} else if (id == NotificationCenter.mediaCountDidLoaded) { } else if (id == NotificationCenter.mediaCountDidLoaded) {
long uid = (Long) args[0]; long uid = (Long) args[0];
if (uid == currentDialogId) { if (uid == currentDialogId || uid == mergeDialogId) {
if ((int) currentDialogId != 0 && (Boolean) args[2]) { if (uid == currentDialogId) {
SharedMediaQuery.getMediaCount(currentDialogId, SharedMediaQuery.MEDIA_PHOTOVIDEO, classGuid, false); totalImagesCount = (Integer) args[1];
if ((Boolean) args[2]) {
SharedMediaQuery.getMediaCount(currentDialogId, SharedMediaQuery.MEDIA_PHOTOVIDEO, classGuid, false);
}
} else if (uid == mergeDialogId) {
totalImagesCountMerge = (Integer) args[1];
if ((Boolean) args[2]) {
SharedMediaQuery.getMediaCount(mergeDialogId, SharedMediaQuery.MEDIA_PHOTOVIDEO, classGuid, false);
}
} }
totalImagesCount = (Integer) args[1];
if (needSearchImageInArr && isFirstLoading) { if (needSearchImageInArr && isFirstLoading) {
isFirstLoading = false; isFirstLoading = false;
loadingMoreImages = true; loadingMoreImages = true;
SharedMediaQuery.loadMedia(currentDialogId, 0, 80, 0, SharedMediaQuery.MEDIA_PHOTOVIDEO, true, classGuid); SharedMediaQuery.loadMedia(currentDialogId, 0, 80, 0, SharedMediaQuery.MEDIA_PHOTOVIDEO, true, classGuid);
} else if (!imagesArr.isEmpty()) { } else if (!imagesArr.isEmpty()) {
if (opennedFromMedia) { if (opennedFromMedia) {
actionBar.setTitle(LocaleController.formatString("Of", R.string.Of, currentIndex + 1, totalImagesCount)); actionBar.setTitle(LocaleController.formatString("Of", R.string.Of, currentIndex + 1, totalImagesCount + totalImagesCountMerge));
} else { } else {
actionBar.setTitle(LocaleController.formatString("Of", R.string.Of, (totalImagesCount - imagesArr.size()) + currentIndex + 1, totalImagesCount)); actionBar.setTitle(LocaleController.formatString("Of", R.string.Of, (totalImagesCount + totalImagesCountMerge - imagesArr.size()) + currentIndex + 1, totalImagesCount + totalImagesCountMerge));
} }
} }
} }
} else if (id == NotificationCenter.mediaDidLoaded) { } else if (id == NotificationCenter.mediaDidLoaded) {
long uid = (Long) args[0]; long uid = (Long) args[0];
int guid = (Integer) args[3]; int guid = (Integer) args[3];
if (uid == currentDialogId && guid == classGuid) { if ((uid == currentDialogId || uid == mergeDialogId) && guid == classGuid) {
loadingMoreImages = false; loadingMoreImages = false;
int loadIndex = uid == currentDialogId ? 0 : 1;
ArrayList<MessageObject> arr = (ArrayList<MessageObject>) args[2]; ArrayList<MessageObject> arr = (ArrayList<MessageObject>) args[2];
endReached = (Boolean) args[5]; endReached[loadIndex] = (Boolean) args[5];
if (needSearchImageInArr) { if (needSearchImageInArr) {
if (arr.isEmpty()) { if (arr.isEmpty() && (loadIndex != 0 || mergeDialogId == 0)) {
needSearchImageInArr = false; needSearchImageInArr = false;
return; return;
} }
@ -766,9 +781,10 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
MessageObject currentMessage = imagesArr.get(currentIndex); MessageObject currentMessage = imagesArr.get(currentIndex);
int added = 0; int added = 0;
for (MessageObject message : arr) { for (int a = 0; a < arr.size(); a++) {
if (!imagesByIdsTemp.containsKey(message.getId())) { MessageObject message = arr.get(a);
imagesByIdsTemp.put(message.getId(), message); if (!imagesByIdsTemp[loadIndex].containsKey(message.getId())) {
imagesByIdsTemp[loadIndex].put(message.getId(), message);
if (opennedFromMedia) { if (opennedFromMedia) {
imagesArrTemp.add(message); imagesArrTemp.add(message);
if (message.getId() == currentMessage.getId()) { if (message.getId() == currentMessage.getId()) {
@ -784,17 +800,20 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
} }
} }
} }
if (added == 0) { if (added == 0 && (loadIndex != 0 || mergeDialogId == 0)) {
totalImagesCount = imagesArr.size(); totalImagesCount = imagesArr.size();
totalImagesCountMerge = 0;
} }
if (foundIndex != -1) { if (foundIndex != -1) {
imagesArr.clear(); imagesArr.clear();
imagesArr.addAll(imagesArrTemp); imagesArr.addAll(imagesArrTemp);
imagesByIds.clear(); for (int a = 0; a < 2; a++) {
imagesByIds.putAll(imagesByIdsTemp); imagesByIds[a].clear();
imagesByIds[a].putAll(imagesByIdsTemp[a]);
imagesByIdsTemp[a].clear();
}
imagesArrTemp.clear(); imagesArrTemp.clear();
imagesByIdsTemp.clear();
needSearchImageInArr = false; needSearchImageInArr = false;
currentIndex = -1; currentIndex = -1;
if (foundIndex >= imagesArr.size()) { if (foundIndex >= imagesArr.size()) {
@ -802,31 +821,51 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
} }
setImageIndex(foundIndex, true); setImageIndex(foundIndex, true);
} else { } else {
if (!endReached || !arr.isEmpty() && added != 0) { int loadFromMaxId;
if (opennedFromMedia) {
loadFromMaxId = imagesArrTemp.isEmpty() ? 0 : imagesArrTemp.get(imagesArrTemp.size() - 1).getId();
if (loadIndex == 0 && endReached[loadIndex] && mergeDialogId != 0) {
loadIndex = 1;
if (!imagesArrTemp.isEmpty() && imagesArrTemp.get(imagesArrTemp.size() - 1).getDialogId() != mergeDialogId) {
loadFromMaxId = 0;
}
}
} else {
loadFromMaxId = imagesArrTemp.isEmpty() ? 0 : imagesArrTemp.get(0).getId();
if (loadIndex == 0 && endReached[loadIndex] && mergeDialogId != 0) {
loadIndex = 1;
if (!imagesArrTemp.isEmpty() && imagesArrTemp.get(0).getDialogId() != mergeDialogId) {
loadFromMaxId = 0;
}
}
}
if (!endReached[loadIndex]) {
loadingMoreImages = true; loadingMoreImages = true;
if (opennedFromMedia) { if (opennedFromMedia) {
SharedMediaQuery.loadMedia(currentDialogId, 0, 80, imagesArrTemp.get(imagesArrTemp.size() - 1).getId(), SharedMediaQuery.MEDIA_PHOTOVIDEO, true, classGuid); SharedMediaQuery.loadMedia(loadIndex == 0 ? currentDialogId : mergeDialogId, 0, 80, loadFromMaxId, SharedMediaQuery.MEDIA_PHOTOVIDEO, true, classGuid);
} else { } else {
SharedMediaQuery.loadMedia(currentDialogId, 0, 80, imagesArrTemp.get(0).getId(), SharedMediaQuery.MEDIA_PHOTOVIDEO, true, classGuid); SharedMediaQuery.loadMedia(loadIndex == 0 ? currentDialogId : mergeDialogId, 0, 80, loadFromMaxId, SharedMediaQuery.MEDIA_PHOTOVIDEO, true, classGuid);
} }
} }
} }
} else { } else {
int added = 0; int added = 0;
for (MessageObject message : arr) { for (MessageObject message : arr) {
if (!imagesByIds.containsKey(message.getId())) { if (!imagesByIds[loadIndex].containsKey(message.getId())) {
added++; added++;
if (opennedFromMedia) { if (opennedFromMedia) {
imagesArr.add(message); imagesArr.add(message);
} else { } else {
imagesArr.add(0, message); imagesArr.add(0, message);
} }
imagesByIds.put(message.getId(), message); imagesByIds[loadIndex].put(message.getId(), message);
} }
} }
if (opennedFromMedia) { if (opennedFromMedia) {
if (added == 0) { if (added == 0) {
totalImagesCount = imagesArr.size(); totalImagesCount = imagesArr.size();
totalImagesCountMerge = 0;
} }
} else { } else {
if (added != 0) { if (added != 0) {
@ -835,6 +874,7 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
setImageIndex(index + added, true); setImageIndex(index + added, true);
} else { } else {
totalImagesCount = imagesArr.size(); totalImagesCount = imagesArr.size();
totalImagesCountMerge = 0;
} }
} }
} }
@ -924,7 +964,6 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
GradientDrawable gd = new GradientDrawable(go, colors); GradientDrawable gd = new GradientDrawable(go, colors);
actionBar.setBackgroundDrawable(gd); actionBar.setBackgroundDrawable(gd);
} }
actionBar.setOccupyStatusBar(false); actionBar.setOccupyStatusBar(false);
actionBar.setItemsBackground(R.drawable.bar_selector_white); actionBar.setItemsBackground(R.drawable.bar_selector_white);
//actionBar.setBackButtonImage(R.drawable.ic_ab_back); //actionBar.setBackButtonImage(R.drawable.ic_ab_back);
@ -2226,13 +2265,14 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
currentFileNames[1] = null; currentFileNames[1] = null;
currentFileNames[2] = null; currentFileNames[2] = null;
avatarsUserId = 0; avatarsUserId = 0;
currentDialogId = 0;
totalImagesCount = 0; totalImagesCount = 0;
totalImagesCountMerge = 0;
currentEditMode = 0; currentEditMode = 0;
isFirstLoading = true; isFirstLoading = true;
needSearchImageInArr = false; needSearchImageInArr = false;
loadingMoreImages = false; loadingMoreImages = false;
endReached = false; endReached[0] = false;
endReached[1] = mergeDialogId == 0;
opennedFromMedia = false; opennedFromMedia = false;
needCaptionLayout = false; needCaptionLayout = false;
canShowBottom = true; canShowBottom = true;
@ -2241,9 +2281,11 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
imagesArrLocationsSizes.clear(); imagesArrLocationsSizes.clear();
avatarsArr.clear(); avatarsArr.clear();
imagesArrLocals.clear(); imagesArrLocals.clear();
imagesByIds.clear(); for (int a = 0; a < 2; a++) {
imagesByIds[a].clear();
imagesByIdsTemp[a].clear();
}
imagesArrTemp.clear(); imagesArrTemp.clear();
imagesByIdsTemp.clear();
currentUserAvatarLocation = null; currentUserAvatarLocation = null;
containerView.setPadding(0, 0, 0, 0); containerView.setPadding(0, 0, 0, 0);
currentThumb = object != null ? object.thumb : null; currentThumb = object != null ? object.thumb : null;
@ -2290,8 +2332,7 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
imagesArr.add(messageObject); imagesArr.add(messageObject);
if (!(messageObject.messageOwner.media instanceof TLRPC.TL_messageMediaWebPage) && (messageObject.messageOwner.action == null || messageObject.messageOwner.action instanceof TLRPC.TL_messageActionEmpty)) { if (!(messageObject.messageOwner.media instanceof TLRPC.TL_messageMediaWebPage) && (messageObject.messageOwner.action == null || messageObject.messageOwner.action instanceof TLRPC.TL_messageActionEmpty)) {
needSearchImageInArr = true; needSearchImageInArr = true;
imagesByIds.put(messageObject.getId(), messageObject); imagesByIds[0].put(messageObject.getId(), messageObject);
currentDialogId = messageObject.getDialogId();
menuItem.showSubItem(gallery_menu_showall); menuItem.showSubItem(gallery_menu_showall);
} else { } else {
menuItem.hideSubItem(gallery_menu_showall); menuItem.hideSubItem(gallery_menu_showall);
@ -2315,18 +2356,9 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
Collections.reverse(imagesArr); Collections.reverse(imagesArr);
index = imagesArr.size() - index - 1; index = imagesArr.size() - index - 1;
} }
for (MessageObject message : imagesArr) { for (int a = 0; a < imagesArr.size(); a++) {
imagesByIds.put(message.getId(), message); MessageObject message = imagesArr.get(a);
} imagesByIds[message.getDialogId() == currentDialogId ? 0 : 1].put(message.getId(), message);
if (messageObject.messageOwner.dialog_id != 0) {
currentDialogId = messageObject.messageOwner.dialog_id;
} else {
if (messageObject.messageOwner.to_id == null) {
closePhoto(false, false);
return;
}
currentDialogId = messageObject.getDialogId();
} }
setImageIndex(index, true); setImageIndex(index, true);
} else if (photos != null) { } else if (photos != null) {
@ -2360,6 +2392,9 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
if (currentDialogId != 0 && totalImagesCount == 0) { if (currentDialogId != 0 && totalImagesCount == 0) {
SharedMediaQuery.getMediaCount(currentDialogId, SharedMediaQuery.MEDIA_PHOTOVIDEO, classGuid, true); SharedMediaQuery.getMediaCount(currentDialogId, SharedMediaQuery.MEDIA_PHOTOVIDEO, classGuid, true);
if (mergeDialogId != 0) {
SharedMediaQuery.getMediaCount(mergeDialogId, SharedMediaQuery.MEDIA_PHOTOVIDEO, classGuid, true);
}
} else if (avatarsUserId != 0) { } else if (avatarsUserId != 0) {
MessagesController.getInstance().loadUserPhotos(avatarsUserId, 0, 80, 0, true, classGuid); MessagesController.getInstance().loadUserPhotos(avatarsUserId, 0, 80, 0, true, classGuid);
} }
@ -2401,12 +2436,12 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
menuItem.hideSubItem(gallery_menu_delete); menuItem.hideSubItem(gallery_menu_delete);
} }
if (currentMessageObject.messageOwner.from_id > 0) { if (currentMessageObject.messageOwner.from_id > 0) {
TLRPC.User user = MessagesController.getInstance().getUser(currentMessageObject.messageOwner.from_id); TLRPC.User user = MessagesController.getInstance().getUser(currentMessageObject.messageOwner.from_id);
if (user != null) { if (user != null) {
nameTextView.setText(UserObject.getUserName(user)); nameTextView.setText(UserObject.getUserName(user));
} else { } else {
nameTextView.setText(""); nameTextView.setText("");
} }
} else { } else {
TLRPC.Chat chat = MessagesController.getInstance().getChat(-currentMessageObject.messageOwner.from_id); TLRPC.Chat chat = MessagesController.getInstance().getChat(-currentMessageObject.messageOwner.from_id);
if (chat != null) { if (chat != null) {
@ -2416,7 +2451,7 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
} }
} }
long date = (long) currentMessageObject.messageOwner.date * 1000; long date = (long) currentMessageObject.messageOwner.date * 1000;
String dateString = LocaleController.formatString("formatDateAtTime", R.string.formatDateAtTime, LocaleController.formatterYear.format(new Date(date)), LocaleController.formatterDay.format(new Date(date))); String dateString = LocaleController.formatString("formatDateAtTime", R.string.formatDateAtTime, LocaleController.getInstance().formatterYear.format(new Date(date)), LocaleController.getInstance().formatterDay.format(new Date(date)));
if (currentFileNames[0] != null && currentFileNames[0].endsWith("mp4")) { if (currentFileNames[0] != null && currentFileNames[0].endsWith("mp4")) {
dateTextView.setText(String.format("%s (%s)", dateString, AndroidUtilities.formatFileSize(currentMessageObject.messageOwner.media.video.size))); dateTextView.setText(String.format("%s (%s)", dateString, AndroidUtilities.formatFileSize(currentMessageObject.messageOwner.media.video.size)));
} else { } else {
@ -2425,21 +2460,37 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
CharSequence caption = currentMessageObject.caption; CharSequence caption = currentMessageObject.caption;
setCurrentCaption(caption); setCurrentCaption(caption);
if (totalImagesCount != 0 && !needSearchImageInArr) { if (totalImagesCount + totalImagesCountMerge != 0 && !needSearchImageInArr) {
if (opennedFromMedia) { if (opennedFromMedia) {
if (imagesArr.size() < totalImagesCount && !loadingMoreImages && currentIndex > imagesArr.size() - 5) { if (imagesArr.size() < totalImagesCount + totalImagesCountMerge && !loadingMoreImages && currentIndex > imagesArr.size() - 5) {
MessageObject lastMessage = imagesArr.get(imagesArr.size() - 1); int loadFromMaxId = imagesArr.isEmpty() ? 0 : imagesArr.get(imagesArr.size() - 1).getId();
SharedMediaQuery.loadMedia(currentDialogId, 0, 80, lastMessage.getId(), SharedMediaQuery.MEDIA_PHOTOVIDEO, true, classGuid); int loadIndex = 0;
if (endReached[loadIndex] && mergeDialogId != 0) {
loadIndex = 1;
if (!imagesArr.isEmpty() && imagesArr.get(imagesArr.size() - 1).getDialogId() != mergeDialogId) {
loadFromMaxId = 0;
}
}
SharedMediaQuery.loadMedia(loadIndex == 0 ? currentDialogId : mergeDialogId, 0, 80, loadFromMaxId, SharedMediaQuery.MEDIA_PHOTOVIDEO, true, classGuid);
loadingMoreImages = true; loadingMoreImages = true;
} }
actionBar.setTitle(LocaleController.formatString("Of", R.string.Of, currentIndex + 1, totalImagesCount)); actionBar.setTitle(LocaleController.formatString("Of", R.string.Of, currentIndex + 1, totalImagesCount + totalImagesCountMerge));
} else { } else {
if (imagesArr.size() < totalImagesCount && !loadingMoreImages && currentIndex < 5) { if (imagesArr.size() < totalImagesCount + totalImagesCountMerge && !loadingMoreImages && currentIndex < 5) {
MessageObject lastMessage = imagesArr.get(0); int loadFromMaxId = imagesArr.isEmpty() ? 0 : imagesArr.get(0).getId();
SharedMediaQuery.loadMedia(currentDialogId, 0, 80, lastMessage.getId(), SharedMediaQuery.MEDIA_PHOTOVIDEO, true, classGuid); int loadIndex = 0;
if (endReached[loadIndex] && mergeDialogId != 0) {
loadIndex = 1;
if (!imagesArr.isEmpty() && imagesArr.get(0).getDialogId() != mergeDialogId) {
loadFromMaxId = 0;
}
}
SharedMediaQuery.loadMedia(loadIndex == 0 ? currentDialogId : mergeDialogId, 0, 80, loadFromMaxId, SharedMediaQuery.MEDIA_PHOTOVIDEO, true, classGuid);
loadingMoreImages = true; loadingMoreImages = true;
} }
actionBar.setTitle(LocaleController.formatString("Of", R.string.Of, (totalImagesCount - imagesArr.size()) + currentIndex + 1, totalImagesCount)); actionBar.setTitle(LocaleController.formatString("Of", R.string.Of, (totalImagesCount + totalImagesCountMerge - imagesArr.size()) + currentIndex + 1, totalImagesCount + totalImagesCountMerge));
} }
} else if (currentMessageObject.messageOwner.media instanceof TLRPC.TL_messageMediaWebPage) { } else if (currentMessageObject.messageOwner.media instanceof TLRPC.TL_messageMediaWebPage) {
actionBar.setTitle(LocaleController.getString("AttachPhoto", R.string.AttachPhoto)); actionBar.setTitle(LocaleController.getString("AttachPhoto", R.string.AttachPhoto));
@ -2797,16 +2848,16 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
return isVisible && !disableShowCheck && object != null && currentPathObject != null && object.equals(currentPathObject); return isVisible && !disableShowCheck && object != null && currentPathObject != null && object.equals(currentPathObject);
} }
public void openPhoto(final MessageObject messageObject, final PhotoViewerProvider provider) { public void openPhoto(final MessageObject messageObject, long dialogId, long mergeDialogId, final PhotoViewerProvider provider) {
openPhoto(messageObject, null, null, null, 0, provider, null); openPhoto(messageObject, null, null, null, 0, provider, null, dialogId, mergeDialogId);
} }
public void openPhoto(final TLRPC.FileLocation fileLocation, final PhotoViewerProvider provider) { public void openPhoto(final TLRPC.FileLocation fileLocation, final PhotoViewerProvider provider) {
openPhoto(null, fileLocation, null, null, 0, provider, null); openPhoto(null, fileLocation, null, null, 0, provider, null, 0, 0);
} }
public void openPhoto(final ArrayList<MessageObject> messages, final int index, final PhotoViewerProvider provider) { public void openPhoto(final ArrayList<MessageObject> messages, final int index, long dialogId, long mergeDialogId, final PhotoViewerProvider provider) {
openPhoto(messages.get(index), null, messages, null, index, provider, null); openPhoto(messages.get(index), null, messages, null, index, provider, null, dialogId, mergeDialogId);
} }
public void openPhotoForSelect(final ArrayList<Object> photos, final int index, int type, final PhotoViewerProvider provider, ChatActivity chatActivity) { public void openPhotoForSelect(final ArrayList<Object> photos, final int index, int type, final PhotoViewerProvider provider, ChatActivity chatActivity) {
@ -2814,7 +2865,7 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
if (pickerView != null) { if (pickerView != null) {
pickerView.doneButtonTextView.setText(sendPhotoType == 1 ? LocaleController.getString("Set", R.string.Set).toUpperCase() : LocaleController.getString("Send", R.string.Send).toUpperCase()); pickerView.doneButtonTextView.setText(sendPhotoType == 1 ? LocaleController.getString("Set", R.string.Set).toUpperCase() : LocaleController.getString("Send", R.string.Send).toUpperCase());
} }
openPhoto(null, null, null, photos, index, provider, chatActivity); openPhoto(null, null, null, photos, index, provider, chatActivity, 0, 0);
} }
private boolean checkAnimation() { private boolean checkAnimation() {
@ -2830,7 +2881,7 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
return animationInProgress != 0; return animationInProgress != 0;
} }
public void openPhoto(final MessageObject messageObject, final TLRPC.FileLocation fileLocation, final ArrayList<MessageObject> messages, final ArrayList<Object> photos, final int index, final PhotoViewerProvider provider, ChatActivity chatActivity) { public void openPhoto(final MessageObject messageObject, final TLRPC.FileLocation fileLocation, final ArrayList<MessageObject> messages, final ArrayList<Object> photos, final int index, final PhotoViewerProvider provider, ChatActivity chatActivity, long dialogId, long mDialogId) {
if (parentActivity == null || isVisible || provider == null && checkAnimation() || messageObject == null && fileLocation == null && messages == null && photos == null) { if (parentActivity == null || isVisible || provider == null && checkAnimation() || messageObject == null && fileLocation == null && messages == null && photos == null) {
return; return;
} }
@ -2850,11 +2901,11 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
} }
try { try {
windowLayoutParams.type = WindowManager.LayoutParams.LAST_APPLICATION_WINDOW; windowLayoutParams.type = WindowManager.LayoutParams.LAST_APPLICATION_WINDOW;
windowLayoutParams.flags = WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE; windowLayoutParams.flags = WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE;
windowLayoutParams.softInputMode = WindowManager.LayoutParams.SOFT_INPUT_ADJUST_UNSPECIFIED; windowLayoutParams.softInputMode = WindowManager.LayoutParams.SOFT_INPUT_ADJUST_UNSPECIFIED;
windowView.setFocusable(false); windowView.setFocusable(false);
containerView.setFocusable(false); containerView.setFocusable(false);
wm.addView(windowView, windowLayoutParams); wm.addView(windowView, windowLayoutParams);
} catch (Exception e) { } catch (Exception e) {
FileLog.e("tmessages", e); FileLog.e("tmessages", e);
@ -2873,6 +2924,8 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
NotificationCenter.getInstance().addObserver(this, NotificationCenter.emojiDidLoaded); NotificationCenter.getInstance().addObserver(this, NotificationCenter.emojiDidLoaded);
placeProvider = provider; placeProvider = provider;
mergeDialogId = mDialogId;
currentDialogId = dialogId;
if (velocityTracker == null) { if (velocityTracker == null) {
velocityTracker = VelocityTracker.obtain(); velocityTracker = VelocityTracker.obtain();
@ -2919,7 +2972,7 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
int coords2[] = new int[2]; int coords2[] = new int[2];
object.parentView.getLocationInWindow(coords2); object.parentView.getLocationInWindow(coords2);
int clipTop = coords2[1] - AndroidUtilities.statusBarHeight - (object.viewY + drawRegion.top); int clipTop = coords2[1] - AndroidUtilities.statusBarHeight - (object.viewY + drawRegion.top) + object.clipTopAddition;
if (clipTop < 0) { if (clipTop < 0) {
clipTop = 0; clipTop = 0;
} }
@ -3141,7 +3194,7 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
int coords2[] = new int[2]; int coords2[] = new int[2];
object.parentView.getLocationInWindow(coords2); object.parentView.getLocationInWindow(coords2);
int clipTop = coords2[1] - AndroidUtilities.statusBarHeight - (object.viewY + drawRegion.top); int clipTop = coords2[1] - AndroidUtilities.statusBarHeight - (object.viewY + drawRegion.top) + object.clipTopAddition;
if (clipTop < 0) { if (clipTop < 0) {
clipTop = 0; clipTop = 0;
} }

View File

@ -298,7 +298,7 @@ public class PopupNotificationActivity extends Activity implements NotificationC
if (currentMessageNum >= 0 && currentMessageNum < NotificationsController.getInstance().popupMessages.size()) { if (currentMessageNum >= 0 && currentMessageNum < NotificationsController.getInstance().popupMessages.size()) {
NotificationsController.getInstance().popupMessages.remove(currentMessageNum); NotificationsController.getInstance().popupMessages.remove(currentMessageNum);
} }
MessagesController.getInstance().markDialogAsRead(currentMessageObject.getDialogId(), currentMessageObject.getId(), Math.max(0, currentMessageObject.getId()), 0, currentMessageObject.messageOwner.date, true, true); MessagesController.getInstance().markDialogAsRead(currentMessageObject.getDialogId(), currentMessageObject.getId(), Math.max(0, currentMessageObject.getId()), currentMessageObject.messageOwner.date, true, true);
currentMessageObject = null; currentMessageObject = null;
getNewMessage(); getNewMessage();
} }

View File

@ -30,6 +30,7 @@ import org.telegram.messenger.ApplicationLoader;
import org.telegram.tgnet.ConnectionsManager; import org.telegram.tgnet.ConnectionsManager;
import org.telegram.messenger.FileLog; import org.telegram.messenger.FileLog;
import org.telegram.messenger.R; import org.telegram.messenger.R;
import org.telegram.tgnet.ConnectionsManager;
import org.telegram.tgnet.RequestDelegate; import org.telegram.tgnet.RequestDelegate;
import org.telegram.tgnet.TLObject; import org.telegram.tgnet.TLObject;
import org.telegram.tgnet.TLRPC; import org.telegram.tgnet.TLRPC;

View File

@ -178,6 +178,9 @@ public class ProfileNotificationsActivity extends BaseFragment implements Notifi
SharedPreferences preferences = ApplicationLoader.applicationContext.getSharedPreferences("Notifications", Activity.MODE_PRIVATE); SharedPreferences preferences = ApplicationLoader.applicationContext.getSharedPreferences("Notifications", Activity.MODE_PRIVATE);
SharedPreferences.Editor editor = preferences.edit(); SharedPreferences.Editor editor = preferences.edit();
editor.putInt("notify2_" + dialog_id, which); editor.putInt("notify2_" + dialog_id, which);
if (which == 2) {
NotificationsController.getInstance().removeNotificationsForDialog(dialog_id);
}
MessagesStorage.getInstance().setDialogFlags(dialog_id, which == 2 ? 1 : 0); MessagesStorage.getInstance().setDialogFlags(dialog_id, which == 2 ? 1 : 0);
editor.commit(); editor.commit();
TLRPC.Dialog dialog = MessagesController.getInstance().dialogs_dict.get(dialog_id); TLRPC.Dialog dialog = MessagesController.getInstance().dialogs_dict.get(dialog_id);

View File

@ -1384,7 +1384,7 @@ public class SettingsActivity extends BaseFragment implements NotificationCenter
} else if (i == sendLogsRow) { } else if (i == sendLogsRow) {
textCell.setText(LocaleController.getString("SendLogs", R.string.SendLogs), true); textCell.setText(LocaleController.getString("SendLogs", R.string.SendLogs), true);
} else if (i == clearLogsRow) { } else if (i == clearLogsRow) {
textCell.setText("Clear Logs", false); textCell.setText(LocaleController.getString("ClearLogs", R.string.ClearLogs), false);
} else if (i == askQuestionRow) { } else if (i == askQuestionRow) {
textCell.setText(LocaleController.getString("AskAQuestion", R.string.AskAQuestion), true); textCell.setText(LocaleController.getString("AskAQuestion", R.string.AskAQuestion), true);
} else if (i == privacyRow) { } else if (i == privacyRow) {

View File

@ -4,6 +4,7 @@
<resources> <resources>
<string name="AppName">Plus Messenger</string> <string name="AppName">Plus Messenger</string>
<string name="AppNameBeta">نسخة تيليجرام التجريبية</string>
<string name="LanguageName">العربية</string> <string name="LanguageName">العربية</string>
<string name="LanguageNameInEnglish">Arabic</string> <string name="LanguageNameInEnglish">Arabic</string>
<string name="LanguageCode">ar</string> <string name="LanguageCode">ar</string>
@ -60,7 +61,28 @@
<string name="MuteDisable">تعطيل</string> <string name="MuteDisable">تعطيل</string>
<string name="Hashtags">الأوسمة</string> <string name="Hashtags">الأوسمة</string>
<string name="Recent">حديث</string> <string name="Recent">حديث</string>
<string name="LinkPreview">معاينة الرابط</string>
<!--channels--> <!--channels-->
<string name="SetAsAdmin">ترقية ليكون مشرف</string>
<string name="DescriptionInfoMega">يمكنك كتابة وصف اختياري لمجموعتك.</string>
<string name="LeaveMega">مغادرة المجموعة</string>
<string name="DeleteMega">حذف المجموعة</string>
<string name="LeaveMegaMenu">مغادرة المجموعة</string>
<string name="DeleteMegaMenu">حذف المجموعة</string>
<string name="MegaDeleteInfo">ستخسر كافة الرسائل في هذه المجموعة.</string>
<string name="MegaAdminsInfo">يمكنك إضافة إداريّين لمساعدتك في إدارة المجموعة. اضغط باستمرار لحذف الإداريين.</string>
<string name="MegaDeleteAlert">لحظة! حذف هذه المجموعة سيزيل كافة الأعضاء والرسائل سيتم حذفها. هل أنت متأكد من رغبتك في حذف المجموعة؟</string>
<string name="ActionCreateMega">تم إنشاء مجموعة</string>
<string name="MegaAddedBy">un1 قام بإضافتك لهذه المجموعة</string>
<string name="MegaLeaveAlert">هل أنت متأكد من أنك تريد الخروج من المجموعة؟</string>
<string name="GroupUserCantAdd">المعذرة، لا يمكنك إضافة هذا المستخدم للمجموعات.</string>
<string name="GroupUserAddLimit">المعذرة، المجموعة ممتلئة.</string>
<string name="GroupUserLeftError">المعذرة, هذا المستخدم قرر مغادرة المجموعة, لا يمكنك دعوته مرة أخرى للمجموعة.</string>
<string name="GroupUserCantAdmin">المعذرة، يوجد الكثير من المشرفين في هذه المجموعة.</string>
<string name="GroupUserCantBot">المعذرة، يوجد الكثير من حسابات البوت في هذه المجموعة.</string>
<string name="ActionMigrateFromGroup">تم ترقية هذه المجموعة لتصبح مجموعة خارقة</string>
<string name="ActionMigrateFromGroupNotify">تم ترقية المجموعة %1$s لتصبح مجموعة خارقة</string>
<string name="NoBlockedGroup">أعضاء القائمة السوداء هم أعضاء تم حذفهم من المجموعة ولا يمكنهم العودة لها إلى بدعوة من المشرف. روابط الدعوة لن تمكنهم من العودة للمجموعة.</string>
<string name="NewChannel">قناة جديدة</string> <string name="NewChannel">قناة جديدة</string>
<string name="EnterChannelName">اسم القناة</string> <string name="EnterChannelName">اسم القناة</string>
<string name="Comments">التعليقات</string> <string name="Comments">التعليقات</string>
@ -111,7 +133,6 @@
<string name="ActionChannelChangedPhoto">تم تغيير صورة القناة</string> <string name="ActionChannelChangedPhoto">تم تغيير صورة القناة</string>
<string name="ActionChannelRemovedPhoto">تم حذف صورة القناة</string> <string name="ActionChannelRemovedPhoto">تم حذف صورة القناة</string>
<string name="ActionChannelChangedTitle">تم تغيير اسم القناة إلى un2</string> <string name="ActionChannelChangedTitle">تم تغيير اسم القناة إلى un2</string>
<string name="ActionChannelInvite">un1 قام بإضافتك لقناة un2</string>
<string name="ChannelPublicLimitReached">المعذرة، قمت بإنشاء قنوات عامة كثيرة. يمكنك إنشاء قناة خاصة أو حذف أحد القنوات العامة أولًا.</string> <string name="ChannelPublicLimitReached">المعذرة، قمت بإنشاء قنوات عامة كثيرة. يمكنك إنشاء قناة خاصة أو حذف أحد القنوات العامة أولًا.</string>
<string name="ChannelModerator">المراقب</string> <string name="ChannelModerator">المراقب</string>
<string name="ChannelCreator">المنشئ</string> <string name="ChannelCreator">المنشئ</string>
@ -127,12 +148,12 @@
<string name="ChannelLinkInfo">أي شخص يمتلك تيليجرام على جهازه سيمكنه الدخول لقناتك باستخدام هذا الرابط.</string> <string name="ChannelLinkInfo">أي شخص يمتلك تيليجرام على جهازه سيمكنه الدخول لقناتك باستخدام هذا الرابط.</string>
<string name="ChannelAdminsInfo">يمكنك إضافة إداريّون لمساعدتك في إدارة القناة. اضغط باستمرار لحذف الإداريين.</string> <string name="ChannelAdminsInfo">يمكنك إضافة إداريّون لمساعدتك في إدارة القناة. اضغط باستمرار لحذف الإداريين.</string>
<string name="ChannelJoinTo">هل ترغب في الدخول لقناة \'%1$s\'؟</string> <string name="ChannelJoinTo">هل ترغب في الدخول لقناة \'%1$s\'؟</string>
<string name="ChannelCantOpenPrivate">المعذرة، هذه القناة لم تعد متاحة.</string> <string name="ChannelCantOpenPrivate">المعذرة، هذه المحادثة لم تعد متاحة.</string>
<string name="ChannelAddToTitle">هل ترغب بإضافة %1$s لقناة %2$s؟</string>
<string name="ChannelAddTo">هل ترغب بإضافة %1$s للقناة؟</string> <string name="ChannelAddTo">هل ترغب بإضافة %1$s للقناة؟</string>
<string name="ChannelUserLeftError">المعذرة, هذا المستخدم قرر مغادرة المجموعة, لا يمكنك دعوته مرة أخرى للمجموعة.</string> <string name="ChannelUserLeftError">المعذرة، هذا المستخدم قرر مغادرة القناة, لا يمكنك دعوته مرة أخرى للقناة.</string>
<string name="ChannelUserCantAdd">المعذرة، لا يمكنك إضافة هذا المستخدم للقنوات.</string> <string name="ChannelUserCantAdd">المعذرة، لا يمكنك إضافة هذا المستخدم للقنوات.</string>
<string name="ChannelUserCantAdmin">المعذرة، يوجد الكثير من الإداريين في هذه القناة.</string> <string name="ChannelUserCantAdmin">المعذرة، يوجد الكثير من الإداريين في هذه القناة.</string>
<string name="ChannelUserCantBot">المعذرة، يوجد الكثير من حسابات البوت في هذه القناة.</string>
<string name="ChannelUserAddLimit">المعذرة، يمكنك إضافة أول ٢٠٠ عضو للقناة فقط. يمكن لعدد غير محدود من الأعضاء الدخول للقناة عن طريق رابط القناة.</string> <string name="ChannelUserAddLimit">المعذرة، يمكنك إضافة أول ٢٠٠ عضو للقناة فقط. يمكن لعدد غير محدود من الأعضاء الدخول للقناة عن طريق رابط القناة.</string>
<string name="ChannelAddedBy">un1 قام بإضافتك لهذه القناة</string> <string name="ChannelAddedBy">un1 قام بإضافتك لهذه القناة</string>
<string name="ChannelJoined">لقد قمت بالدخول للقناة.</string> <string name="ChannelJoined">لقد قمت بالدخول للقناة.</string>
@ -242,6 +263,7 @@
<string name="NobodyLikesSpam2">المعذرة، يمكنك فقط إضافة من يمتلك رقمك وتمتلك رقمه للمجموعة في الوقت الحالي.</string> <string name="NobodyLikesSpam2">المعذرة، يمكنك فقط إضافة من يمتلك رقمك وتمتلك رقمه للمجموعة في الوقت الحالي.</string>
<string name="NobodyLikesSpamUrl">https://telegram.org/faq/can-39t-send-messages-to-non-contacts</string> <string name="NobodyLikesSpamUrl">https://telegram.org/faq/can-39t-send-messages-to-non-contacts</string>
<string name="MoreInfo">ملعومات إضافية</string> <string name="MoreInfo">ملعومات إضافية</string>
<string name="ShareSendTo">أرسل إلى...</string>
<!--notification--> <!--notification-->
<string name="MessageLifetimeChanged">%1$s قام بتعيين عداد التدمير الذاتي إلى to %2$s</string> <string name="MessageLifetimeChanged">%1$s قام بتعيين عداد التدمير الذاتي إلى to %2$s</string>
<string name="MessageLifetimeChangedOutgoing">لقد قمت بتعيين التدمير الذاتي إلى %1$s</string> <string name="MessageLifetimeChangedOutgoing">لقد قمت بتعيين التدمير الذاتي إلى %1$s</string>
@ -317,13 +339,22 @@
<string name="CopyLink">نسخ الرابط</string> <string name="CopyLink">نسخ الرابط</string>
<string name="ShareLink">شارك الرابط</string> <string name="ShareLink">شارك الرابط</string>
<string name="LinkInfo">أي شخص يمتلك تيليجرام على جهازه سيسطيع الدخول لمجموعتك باستخدام الرابط التالي.</string> <string name="LinkInfo">أي شخص يمتلك تيليجرام على جهازه سيسطيع الدخول لمجموعتك باستخدام الرابط التالي.</string>
<!--set admins view-->
<string name="SetAdminsTitle">مشرفو المحادثة</string>
<string name="SetAdminsAll">جميع الأعضاء مشرفين</string>
<string name="SetAdminsAllInfo">جميع أعضاء القناة يستطيعون إضافة وحذف الأعضاء، والتعديل على اسم وصورة المجموعة.</string>
<string name="SetAdminsNotAllInfo">فقط مشرفو القناة يستطيعون حذف الأعضاء، والتعديل على اسم وصورة المجموعة.</string>
<!--group info view--> <!--group info view-->
<string name="SharedMedia">عدد الوسائط المشتركة</string> <string name="SharedMedia">عدد الوسائط المشتركة</string>
<string name="SETTINGS">الإعدادات</string> <string name="SETTINGS">الإعدادات</string>
<string name="AddMember">إضافة مشارك</string> <string name="AddMember">إضافة مشارك</string>
<string name="SetAdmins">تعيين كمشرف</string>
<string name="DeleteAndExit">مغادرة المجموعة وحذفها</string> <string name="DeleteAndExit">مغادرة المجموعة وحذفها</string>
<string name="Notifications">الإشعارات</string> <string name="Notifications">الإشعارات</string>
<string name="KickFromGroup">إخراج من المجموعة</string> <string name="KickFromGroup">إخراج من المجموعة</string>
<string name="ConvertGroup">قم بالتحديث لمجموعة خارقة</string>
<string name="ConvertGroupAlert">فضلًا تذكر أن أعضاء هذه المجموعة يلزمهم تحديث تطبيقات تيليجرام لأحدث النسخ ليتمكنوا من الإستفادة من المجموعات الخارقة. هل أنت متأكد من رغبتك في ترقية المجموعة؟</string>
<string name="ConvertGroupInfo"><![CDATA[<b>]]>تم الوصول للحد الأعلى للأعضاء<![CDATA[</b>]]>\n\nيمكنك ترقية مجموعتك لتصبح مجموعة خارقة لتتمكن من إضافة أعضاء أكثر من الحد الأعلى وخصائص مثل:\n\n• الحد الأعلى للأعضاء يصبح %1$s عضو\n• الأعضاء الجدد يرون تاريخ محادثات المجموعة بشكل كامل\n• المشرفون يمكنهم حذف رسائل كافة الأعضاء\n• الإشعارات على وضع الصامت بشكل تلقائي</string>
<!--contact info view--> <!--contact info view-->
<string name="ShareContact">مشاركة</string> <string name="ShareContact">مشاركة</string>
<string name="AddContact">إضافة</string> <string name="AddContact">إضافة</string>
@ -677,6 +708,7 @@
<string name="Call">اتصال</string> <string name="Call">اتصال</string>
<string name="Copy">نسخ</string> <string name="Copy">نسخ</string>
<string name="Delete">حذف</string> <string name="Delete">حذف</string>
<string name="DeleteAndStop">حذف وإيقاف</string>
<string name="Forward">إعادة توجيه</string> <string name="Forward">إعادة توجيه</string>
<string name="Retry">إعادة المحاولة</string> <string name="Retry">إعادة المحاولة</string>
<string name="FromCamera">من الكاميرا</string> <string name="FromCamera">من الكاميرا</string>
@ -731,12 +763,13 @@
<string name="NoHandleAppInstalled">لا يوجد لديك تطبيق يمكنه فتح \'%1$s\'، يرجى تنزيل تطبيق مناسب للإستمرار</string> <string name="NoHandleAppInstalled">لا يوجد لديك تطبيق يمكنه فتح \'%1$s\'، يرجى تنزيل تطبيق مناسب للإستمرار</string>
<string name="InviteUser">هذا المستخدم ليس لديه تيليجرام بعد ، هل ترغب في دعوته الآن؟</string> <string name="InviteUser">هذا المستخدم ليس لديه تيليجرام بعد ، هل ترغب في دعوته الآن؟</string>
<string name="AreYouSure">هل أنت متأكد؟</string> <string name="AreYouSure">هل أنت متأكد؟</string>
<string name="AddToTheGroupTitle">هل ترغب في إضافة %1$s للمجموعة %2$s؟</string> <string name="AddToTheGroupTitle">هل ترغب بإضافة %1$s للمحادثة %2$s؟</string>
<string name="AddToTheGroupForwardCount">عدد الرسائل الحديثة المراد إعادة تحويلها:</string> <string name="AddToTheGroupForwardCount">عدد الرسائل الحديثة المراد إعادة تحويلها:</string>
<string name="AddToTheGroup">إضافة %1$s للمجموعة؟</string> <string name="AddToTheGroup">إضافة %1$s للمجموعة؟</string>
<string name="UserAlreadyInGroup">هذا المستخدم عضو مسبق في هذه المجموعة</string> <string name="UserAlreadyInGroup">هذا المستخدم عضو مسبق في هذه المجموعة</string>
<string name="ForwardMessagesTo">؟%1$s هل تريد إعادة توجيه الرسائل إلى</string> <string name="ForwardMessagesTo">؟%1$s هل تريد إعادة توجيه الرسائل إلى</string>
<string name="SendMessagesTo">هل ترغب في إرسال رسالة إلى %1$s؟</string> <string name="SendMessagesTo">هل ترغب في إرسال رسالة إلى %1$s؟</string>
<string name="SendContactTo">أرسل جهة الاتصال إلى %1$s؟</string>
<string name="AreYouSureLogout">نرجو الأخذ بالعلم أنه يمكنك استخدام تيليجرام على أجهزتك المتعددة بسهولة تامة وفي وقت واحد.\n\nوتذكر، تسجيل الخروج يحذف كافة محادثاتك السرية.</string> <string name="AreYouSureLogout">نرجو الأخذ بالعلم أنه يمكنك استخدام تيليجرام على أجهزتك المتعددة بسهولة تامة وفي وقت واحد.\n\nوتذكر، تسجيل الخروج يحذف كافة محادثاتك السرية.</string>
<string name="AreYouSureSessions">هل أنت متأكد من تسجيل الخروج من جميع الأجهزة الأخرى باستثناء هذا الجهاز؟</string> <string name="AreYouSureSessions">هل أنت متأكد من تسجيل الخروج من جميع الأجهزة الأخرى باستثناء هذا الجهاز؟</string>
<string name="AreYouSureDeleteAndExit">هل أنت متأكد من أنك تريد حذف المجموعة والخروج منها؟</string> <string name="AreYouSureDeleteAndExit">هل أنت متأكد من أنك تريد حذف المجموعة والخروج منها؟</string>
@ -750,6 +783,7 @@
<string name="AreYouSureClearHistory">هل أنت متأكد من رغبتك في حذف سجل المحادثات؟</string> <string name="AreYouSureClearHistory">هل أنت متأكد من رغبتك في حذف سجل المحادثات؟</string>
<string name="AreYouSureDeleteMessages">هل أنت متأكد من رغبتك في حذف %1$s؟</string> <string name="AreYouSureDeleteMessages">هل أنت متأكد من رغبتك في حذف %1$s؟</string>
<string name="SendMessagesToGroup">هل ترغب في إرسال رسالة إلى %1$s؟</string> <string name="SendMessagesToGroup">هل ترغب في إرسال رسالة إلى %1$s؟</string>
<string name="SendContactToGroup">أرسل جهة الاتصال إلى %1$s؟</string>
<string name="ForwardMessagesToGroup">؟%1$s هل تريد إعادة توجيه الرسائل إلى</string> <string name="ForwardMessagesToGroup">؟%1$s هل تريد إعادة توجيه الرسائل إلى</string>
<string name="FeatureUnavailable">.Sorry, this feature is currently not available in your country</string> <string name="FeatureUnavailable">.Sorry, this feature is currently not available in your country</string>
<string name="NoUsernameFound">لا يوجد حساب تيليجرام بهذا الاسم.</string> <string name="NoUsernameFound">لا يوجد حساب تيليجرام بهذا الاسم.</string>
@ -976,8 +1010,8 @@
<string name="formatterDay12H">h:mm a</string> <string name="formatterDay12H">h:mm a</string>
<string name="formatDateAtTime">%1$s الساعة %2$s</string> <string name="formatDateAtTime">%1$s الساعة %2$s</string>
<!--update text--> <!--update text-->
<string name="updateText">تم تحديث تيليجرام على الأندرويد. الجديد في النسخة رقم 3.2.6:\n\n- تحسين للواجهة البصرية للتطبيق\n- دعم للإيموجي الجديدة\n- تحسينات أخرى وإصلاح للثغرات</string> <string name="updateText">تم تحديث تيليجرام على الأندرويد. الجديد في النسخة رقم 3.3.1:\n\n- المجموعات الآن يمكن أن يكون بها عدة مشرفين يمكنهم تغيير اسمها وشعارها وإضافة وإزالة الأعضاء.\n- المجموعات التي وصلت إلى ٢٠٠ عضو يمكن ترقيتها لتصبح مجموعة خارقة تصل إلى ١٠٠٠ عضو.\n- إضافة زر للمشاركة السريعة من خلال القنوات بجانب الرسائل.\n\nللإستزادة عن هذا التحديث من هنا:\nhttps://telegram.org/blog/supergroups</string>
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--><!-- <!--Telegram+--><!--
<string name="updatePlusText"></string>--> <string name="updatePlusText"></string>-->
<string name="TelegramForAndroid">بلاس مسنجر للأندرويد</string> <string name="TelegramForAndroid">بلاس مسنجر للأندرويد</string>

View File

@ -112,7 +112,6 @@ Si no us interessa, us suggerim crear un canal privat.</string>
<string name="ActionChannelChangedPhoto">S\'ha canviat la foto del canal</string> <string name="ActionChannelChangedPhoto">S\'ha canviat la foto del canal</string>
<string name="ActionChannelRemovedPhoto">S\'ha eliminat la foto del canal</string> <string name="ActionChannelRemovedPhoto">S\'ha eliminat la foto del canal</string>
<string name="ActionChannelChangedTitle">S\'ha canviat el nom del canal a un2</string> <string name="ActionChannelChangedTitle">S\'ha canviat el nom del canal a un2</string>
<string name="ActionChannelInvite">un1 us ha afegit al canal un2</string>
<string name="ChannelPublicLimitReached">Heu assolit el nombre màxim de canals públics. Suprimiu els existents o creeu-ne un privat.</string> <string name="ChannelPublicLimitReached">Heu assolit el nombre màxim de canals públics. Suprimiu els existents o creeu-ne un privat.</string>
<string name="ChannelModerator">Moderador</string> <string name="ChannelModerator">Moderador</string>
<string name="ChannelCreator">Creador</string> <string name="ChannelCreator">Creador</string>
@ -129,7 +128,6 @@ Si no us interessa, us suggerim crear un canal privat.</string>
<string name="ChannelAdminsInfo">Podeu afegir administradors perquè us ajudin a gestionar el canal. Mantingueu premut per eliminar-los.</string> <string name="ChannelAdminsInfo">Podeu afegir administradors perquè us ajudin a gestionar el canal. Mantingueu premut per eliminar-los.</string>
<string name="ChannelJoinTo">Voleu afegir-vos al canal «%1$s»?</string> <string name="ChannelJoinTo">Voleu afegir-vos al canal «%1$s»?</string>
<string name="ChannelCantOpenPrivate">Aquest canal ja no és accessible.</string> <string name="ChannelCantOpenPrivate">Aquest canal ja no és accessible.</string>
<string name="ChannelAddToTitle">Voleu afegir %1$s al canal %2$s?</string>
<string name="ChannelAddTo">Voleu afegir %1$s al canal?</string> <string name="ChannelAddTo">Voleu afegir %1$s al canal?</string>
<string name="ChannelUserLeftError">L\'usuari ha decidit abandonar aquest grup, no podeu tornar a convidar-lo.</string> <string name="ChannelUserLeftError">L\'usuari ha decidit abandonar aquest grup, no podeu tornar a convidar-lo.</string>
<string name="ChannelUserCantAdd">No podeu afegir aquest usuari als canals.</string> <string name="ChannelUserCantAdd">No podeu afegir aquest usuari als canals.</string>
@ -976,22 +974,15 @@ Si no us interessa, us suggerim crear un canal privat.</string>
<string name="formatterDay24H">HH:mm</string> <string name="formatterDay24H">HH:mm</string>
<string name="formatterDay12H">h:mm a</string> <string name="formatterDay12H">h:mm a</string>
<string name="formatDateAtTime">%1$s a les %2$s</string> <string name="formatDateAtTime">%1$s a les %2$s</string>
<!--update text--> <!--update text--><!--
<string name="updateText">El Telegram per a Android s\'ha actualitzat. Novetats a la versió 3.2.6: <string name="updateText">El Telegram per a Android s\'ha actualitzat. Novetats a la versió 3.2.6:
- Animacions noves i moltes millores visuals - Animacions noves i moltes millores visuals
- Compatibilitat amb els emojis nous - Compatibilitat amb els emojis nous
- Altres millores i correcció d\'errors</string> - Altres millores i correcció d\'errors</string>
<string name="updateBuild">661</string> <string name="updateBuild">686</string>-->
<!--Telegram+--><!-- <!--Telegram+--><!--
<string name="updatePlusText"> <string name="updatePlusText">\n\nNovetats a la versió 3.3.1.0:\n\n- Correcció d\'errors</string>-->
Novetats a la versió 3.2.6.2:
- S\'ha afegit una modificació per al color de les ordres a la pantalla de xats
- S\'ha afegit una modificació per al color de fons del comptador de missatges als xats/grups/canals silenciats.
- S\'ha afegit una modificació per al color de ressaltat a les cerques en la pantalla principal
- Correcció d\'errors </string>-->
<string name="TelegramForAndroid">Plus Messenger per Android</string> <string name="TelegramForAndroid">Plus Messenger per Android</string>
<string name="Theming">Aparença</string> <string name="Theming">Aparença</string>
<string name="colorHexInvalid">Codi de color hexadecimal no vàlid.</string> <string name="colorHexInvalid">Codi de color hexadecimal no vàlid.</string>

View File

@ -1,6 +1,7 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version="1.0" encoding="utf-8"?>
<resources> <resources>
<string name="AppName">Plus Messenger</string> <string name="AppName">Plus Messenger</string>
<string name="AppNameBeta">Telegram Beta</string>
<string name="LanguageName">Deutsch</string> <string name="LanguageName">Deutsch</string>
<string name="LanguageNameInEnglish">German</string> <string name="LanguageNameInEnglish">German</string>
<string name="LanguageCode">de</string> <string name="LanguageCode">de</string>
@ -57,7 +58,28 @@
<string name="MuteDisable">Dauerhaft Stumm</string> <string name="MuteDisable">Dauerhaft Stumm</string>
<string name="Hashtags">HASHTAGS</string> <string name="Hashtags">HASHTAGS</string>
<string name="Recent">LETZTE</string> <string name="Recent">LETZTE</string>
<string name="LinkPreview">Linkvorschau</string>
<!--channels--> <!--channels-->
<string name="SetAsAdmin">Zum Admin machen</string>
<string name="DescriptionInfoMega">Beschreibe deine Gruppe (optional).</string>
<string name="LeaveMega">Gruppe verlassen</string>
<string name="DeleteMega">Gruppe Löschen</string>
<string name="LeaveMegaMenu">Gruppe verlassen</string>
<string name="DeleteMegaMenu">Gruppe löschen</string>
<string name="MegaDeleteInfo">Du verlierst alle Nachrichten der Gruppe.</string>
<string name="MegaAdminsInfo">Administratoren helfen dir, deinen Kanal zu verwalten. Tippen und halten um sie zu löschen.</string>
<string name="MegaDeleteAlert">Wenn du diese Gruppe löschst, werden alle Mitglieder und alle Nachrichten entfernt. Wirklich löschen?</string>
<string name="ActionCreateMega">Gruppe erstellt</string>
<string name="MegaAddedBy">un1 hat dich hinzugefügt</string>
<string name="MegaLeaveAlert">Möchtest du wirklich diese Gruppe verlassen?</string>
<string name="GroupUserCantAdd">Du kannst diesen Nutzer nicht hinzufügen.</string>
<string name="GroupUserAddLimit">Leider ist diese Gruppe schon voll.</string>
<string name="GroupUserLeftError">Dieser Nutzer hat die Gruppe zu verlassen, deshalb kannst du ihn nicht wieder einladen.</string>
<string name="GroupUserCantAdmin">Es gibt bereits zu viele Administratoren.</string>
<string name="GroupUserCantBot">Es gibt bereits zu viele Bots.</string>
<string name="ActionMigrateFromGroup">Gruppe wurde in eine Supergruppe geändert</string>
<string name="ActionMigrateFromGroupNotify">%1$s wurde in eine Supergruppe geändert</string>
<string name="NoBlockedGroup">Blockierte Nutzer können nur durch Admins erneut hinzugefügt werden. Einladungslinks funktionieren nicht.</string>
<string name="NewChannel">Neuer Kanal</string> <string name="NewChannel">Neuer Kanal</string>
<string name="EnterChannelName">Kanalname</string> <string name="EnterChannelName">Kanalname</string>
<string name="Comments">Kommentare</string> <string name="Comments">Kommentare</string>
@ -108,7 +130,6 @@
<string name="ActionChannelChangedPhoto">Bild geändert</string> <string name="ActionChannelChangedPhoto">Bild geändert</string>
<string name="ActionChannelRemovedPhoto">Bild gelöscht</string> <string name="ActionChannelRemovedPhoto">Bild gelöscht</string>
<string name="ActionChannelChangedTitle">Kanalname zu un2 geändert</string> <string name="ActionChannelChangedTitle">Kanalname zu un2 geändert</string>
<string name="ActionChannelInvite">un1 hat dich zu Kanal un2 hinzugefügt</string>
<string name="ChannelPublicLimitReached">Du hast zu viele öffentliche Kanäle erstellt. Du kannst entweder einen privaten Kanal erstellen oder einen bestehenden Kanal löschen.</string> <string name="ChannelPublicLimitReached">Du hast zu viele öffentliche Kanäle erstellt. Du kannst entweder einen privaten Kanal erstellen oder einen bestehenden Kanal löschen.</string>
<string name="ChannelModerator">Moderator</string> <string name="ChannelModerator">Moderator</string>
<string name="ChannelCreator">Gründer</string> <string name="ChannelCreator">Gründer</string>
@ -124,12 +145,12 @@
<string name="ChannelLinkInfo">Jeder, der Telegram installiert hat, kann anhand dieses Links in deinen Kanal.</string> <string name="ChannelLinkInfo">Jeder, der Telegram installiert hat, kann anhand dieses Links in deinen Kanal.</string>
<string name="ChannelAdminsInfo">Administratoren helfen dir, deinen Kanal zu verwalten. Tippen und halten um sie zu löschen.</string> <string name="ChannelAdminsInfo">Administratoren helfen dir, deinen Kanal zu verwalten. Tippen und halten um sie zu löschen.</string>
<string name="ChannelJoinTo">Möchtest du dem Kanal \'%1$s\' beitreten?</string> <string name="ChannelJoinTo">Möchtest du dem Kanal \'%1$s\' beitreten?</string>
<string name="ChannelCantOpenPrivate">Dieser Kanal ist nicht mehr zugänglich.</string> <string name="ChannelCantOpenPrivate">Dieser Chat ist nicht mehr zugänglich.</string>
<string name="ChannelAddToTitle">%1$s zum Kanal %2$s hinzufügen?</string>
<string name="ChannelAddTo">%1$s zum Kanal hinzufügen?</string> <string name="ChannelAddTo">%1$s zum Kanal hinzufügen?</string>
<string name="ChannelUserLeftError">Dieser Nutzer hat sich entschieden die Gruppe zu verlassen, deshalb kannst du ihn nicht wieder einladen.</string> <string name="ChannelUserLeftError">Dieser Nutzer hat die Gruppe zu verlassen, deshalb kannst du ihn nicht wieder einladen.</string>
<string name="ChannelUserCantAdd">Du kannst diesen Nutzer nicht einladen.</string> <string name="ChannelUserCantAdd">Du kannst diesen Nutzer nicht einladen.</string>
<string name="ChannelUserCantAdmin">Es gibt bereits zu viele Administratoren in diesem Kanal.</string> <string name="ChannelUserCantAdmin">Es gibt bereits zu viele Administratoren in diesem Kanal.</string>
<string name="ChannelUserCantBot">Es gibt bereits zu viele Bots.</string>
<string name="ChannelUserAddLimit">Du kannst nur die ersten 200 Leute einladen, aber unbegrenzt viele können dem Kanal über den Einladungslink beitreten. </string> <string name="ChannelUserAddLimit">Du kannst nur die ersten 200 Leute einladen, aber unbegrenzt viele können dem Kanal über den Einladungslink beitreten. </string>
<string name="ChannelAddedBy">un1 hat dich hinzugefügt</string> <string name="ChannelAddedBy">un1 hat dich hinzugefügt</string>
<string name="ChannelJoined">Du bist dem Kanal beigetreten</string> <string name="ChannelJoined">Du bist dem Kanal beigetreten</string>
@ -239,6 +260,7 @@
<string name="NobodyLikesSpam2">Derzeit kannst du nur Kontakte hinzufügen, die auch deine Nummer haben.</string> <string name="NobodyLikesSpam2">Derzeit kannst du nur Kontakte hinzufügen, die auch deine Nummer haben.</string>
<string name="NobodyLikesSpamUrl">https://telegram.org/faq/de#kann-keine-nachrichten-an-nicht-kontakte-senden</string> <string name="NobodyLikesSpamUrl">https://telegram.org/faq/de#kann-keine-nachrichten-an-nicht-kontakte-senden</string>
<string name="MoreInfo">Mehr Infos</string> <string name="MoreInfo">Mehr Infos</string>
<string name="ShareSendTo">Sende an...</string>
<!--notification--> <!--notification-->
<string name="MessageLifetimeChanged">%1$s hat den Selbstzerstörungs-Timer auf %2$s gesetzt</string> <string name="MessageLifetimeChanged">%1$s hat den Selbstzerstörungs-Timer auf %2$s gesetzt</string>
<string name="MessageLifetimeChangedOutgoing">Du hast den Selbstzerstörungs-Timer auf %1$s gesetzt</string> <string name="MessageLifetimeChangedOutgoing">Du hast den Selbstzerstörungs-Timer auf %1$s gesetzt</string>
@ -314,13 +336,22 @@
<string name="CopyLink">Link kopieren</string> <string name="CopyLink">Link kopieren</string>
<string name="ShareLink">Link teilen</string> <string name="ShareLink">Link teilen</string>
<string name="LinkInfo">Jeder, der Telegram installiert hat, kann anhand dieses Links in deine Gruppe.</string> <string name="LinkInfo">Jeder, der Telegram installiert hat, kann anhand dieses Links in deine Gruppe.</string>
<!--set admins view-->
<string name="SetAdminsTitle">Administratoren</string>
<string name="SetAdminsAll">Alle Mitglieder sind Admins</string>
<string name="SetAdminsAllInfo">Gruppenmitglieder können neue Leute hinzufügen sowie den Gruppennamen und das Bild ändern.</string>
<string name="SetAdminsNotAllInfo">Nur Admins können neue Leute hinzufügen und entfernen, den Gruppennamen und das Bild ändern.</string>
<!--group info view--> <!--group info view-->
<string name="SharedMedia">Geteilte Medien</string> <string name="SharedMedia">Geteilte Medien</string>
<string name="SETTINGS">Einstellungen</string> <string name="SETTINGS">Einstellungen</string>
<string name="AddMember">Mitglied hinzufügen</string> <string name="AddMember">Mitglied hinzufügen</string>
<string name="SetAdmins">Administratoren</string>
<string name="DeleteAndExit">Löschen und Gruppe verlassen</string> <string name="DeleteAndExit">Löschen und Gruppe verlassen</string>
<string name="Notifications">Mitteilungen</string> <string name="Notifications">Mitteilungen</string>
<string name="KickFromGroup">Aus der Gruppe entfernen</string> <string name="KickFromGroup">Aus der Gruppe entfernen</string>
<string name="ConvertGroup">In Supergruppe ändern</string>
<string name="ConvertGroupAlert">Gruppenmitglieder müssen ihre Telegram-App aktualisieren um diese Supergruppe benutzen zu können. Wirklich diese Gruppe in eine Supergruppe ändern?</string>
<string name="ConvertGroupInfo"><![CDATA[<b>]]>Gruppenlimit erreicht.<![CDATA[</b>]]>\n\nFür weitere Funktionen und um das Limit aufzuheben in Supergruppe ändern:\n\n• Bis zu %1$s sind nun möglich\n• Neue Mitglieder sehen gesamten Verlauf\n• Mitteilungen sind standardmäßig stumm\n• Admins können alle Nachrichten löschen</string>
<!--contact info view--> <!--contact info view-->
<string name="ShareContact">Teilen</string> <string name="ShareContact">Teilen</string>
<string name="AddContact">Hinzufügen</string> <string name="AddContact">Hinzufügen</string>
@ -674,6 +705,7 @@
<string name="Call">Anrufen</string> <string name="Call">Anrufen</string>
<string name="Copy">Kopieren</string> <string name="Copy">Kopieren</string>
<string name="Delete">Löschen</string> <string name="Delete">Löschen</string>
<string name="DeleteAndStop">Löschen und Anhalten</string>
<string name="Forward">Weiterleiten</string> <string name="Forward">Weiterleiten</string>
<string name="Retry">Erneut versuchen</string> <string name="Retry">Erneut versuchen</string>
<string name="FromCamera">Von der Kamera</string> <string name="FromCamera">Von der Kamera</string>
@ -728,12 +760,13 @@
<string name="NoHandleAppInstalled">Du hast keine Applikationen, die den Dateityp \'%1$s\' öffnen könnten. Bitte installiere eine entsprechende Anwendung um fortzufahren.</string> <string name="NoHandleAppInstalled">Du hast keine Applikationen, die den Dateityp \'%1$s\' öffnen könnten. Bitte installiere eine entsprechende Anwendung um fortzufahren.</string>
<string name="InviteUser">Dieser Benutzer hat noch kein Telegram. Möchtest du ihn einladen?</string> <string name="InviteUser">Dieser Benutzer hat noch kein Telegram. Möchtest du ihn einladen?</string>
<string name="AreYouSure">Bist du sicher?</string> <string name="AreYouSure">Bist du sicher?</string>
<string name="AddToTheGroupTitle">%1$s zur Gruppe %2$s hinzufügen?</string> <string name="AddToTheGroupTitle">%1$s dem Chat %2$s hinzufügen?</string>
<string name="AddToTheGroupForwardCount">Wieviele der letzten Nachrichten willst du weiterleiten?</string> <string name="AddToTheGroupForwardCount">Wieviele der letzten Nachrichten willst du weiterleiten?</string>
<string name="AddToTheGroup">%1$s zur Gruppe hinzufügen?</string> <string name="AddToTheGroup">%1$s zur Gruppe hinzufügen?</string>
<string name="UserAlreadyInGroup">Nutzer befindet sich schon in der Gruppe</string> <string name="UserAlreadyInGroup">Nutzer befindet sich schon in der Gruppe</string>
<string name="ForwardMessagesTo">Nachrichten an %1$s weiterleiten?</string> <string name="ForwardMessagesTo">Nachrichten an %1$s weiterleiten?</string>
<string name="SendMessagesTo">Nachricht an %1$s senden?</string> <string name="SendMessagesTo">Nachricht an %1$s senden?</string>
<string name="SendContactTo">Kontakt senden an %1$s?</string>
<string name="AreYouSureLogout">Wirklich abmelden?\n\nDu kannst Telegram von all deinen Geräten gleichzeitig nutzen.\n\nWichtig: Abmelden löscht deine Geheimen Chats.</string> <string name="AreYouSureLogout">Wirklich abmelden?\n\nDu kannst Telegram von all deinen Geräten gleichzeitig nutzen.\n\nWichtig: Abmelden löscht deine Geheimen Chats.</string>
<string name="AreYouSureSessions">Sicher, dass du alle anderen Geräte abmelden möchtest?</string> <string name="AreYouSureSessions">Sicher, dass du alle anderen Geräte abmelden möchtest?</string>
<string name="AreYouSureDeleteAndExit">Gruppe löschen und verlassen?</string> <string name="AreYouSureDeleteAndExit">Gruppe löschen und verlassen?</string>
@ -747,6 +780,7 @@
<string name="AreYouSureClearHistory">Möchtest du wirklich den Verlauf löschen?</string> <string name="AreYouSureClearHistory">Möchtest du wirklich den Verlauf löschen?</string>
<string name="AreYouSureDeleteMessages">Sicher, dass du %1$s löschen willst?</string> <string name="AreYouSureDeleteMessages">Sicher, dass du %1$s löschen willst?</string>
<string name="SendMessagesToGroup">Nachricht an %1$s senden?</string> <string name="SendMessagesToGroup">Nachricht an %1$s senden?</string>
<string name="SendContactToGroup">Kontakt senden an %1$s?</string>
<string name="ForwardMessagesToGroup">Weiterleiten an %1$s?</string> <string name="ForwardMessagesToGroup">Weiterleiten an %1$s?</string>
<string name="FeatureUnavailable">Verzeihung, diese Funktion ist derzeit in deinem Land nicht verfügbar.</string> <string name="FeatureUnavailable">Verzeihung, diese Funktion ist derzeit in deinem Land nicht verfügbar.</string>
<string name="NoUsernameFound">Kein Konto mit diesem Benutzernamen</string> <string name="NoUsernameFound">Kein Konto mit diesem Benutzernamen</string>
@ -973,10 +1007,10 @@
<string name="formatterDay12H">h:mm a</string> <string name="formatterDay12H">h:mm a</string>
<string name="formatDateAtTime">%1$s um %2$s</string> <string name="formatDateAtTime">%1$s um %2$s</string>
<!--update text--> <!--update text-->
<string name="updateText">Plus Messenger für Android wurde aktualisiert. Neu in Version 3.2.6:\n\n- Neue Animationen und optische Verbesserungen\n- Neue Emoji\n- Sonstige Verbesserungen und Fehlerbehebungen</string> <string name="updateText">Plus Messenger für Android wurde aktualisiert. Neu in Version 3.3.1:\n\n- Gruppen erlauben ab sofort Administratoren: Diese können den Gruppennamen und das Bild ändern sowie Mitglieder hinzufügen und auch wieder entfernen.\n- Gruppen, die das Limit von 200 Mitgliedern erreicht haben, können in eine Supergruppe (1000 Mitglieder) geändert werden.\n- Kanäle unterstützen schnelles Teilen über den Knopf neben jeder Nachricht.\n\nAusführliche Informationen zu den neuen Funktionen in unserem Blog:\nhttps://telegram.org/blog/supergroups</string>
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--><!-- <!--Telegram+--><!--
<string name="updatePlusText">\n\nNeu in Version 3.2.6.2:\n\n- Now header gets color in android recent apps list\n- Mention list size increased in chat screen\n- Now also channels can be muted from main screen\n- Added mod to set header avatar radius in chat screen\n- Added mod to set typing text color in chat header\n- Fehlerbeseitigungen</string>--> <string name="updatePlusText">\n\nNeu in Version 3.3.1.0:\n\n- Fehlerbeseitigungen</string>-->
<string name="TelegramForAndroid">Plus Messenger für Android</string> <string name="TelegramForAndroid">Plus Messenger für Android</string>
<string name="Theming">Themen bearbeiten</string> <string name="Theming">Themen bearbeiten</string>
<string name="colorHexInvalid">Ungültiger Hex-Code!</string> <string name="colorHexInvalid">Ungültiger Hex-Code!</string>

View File

@ -1,6 +1,10 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version="1.0" encoding="utf-8"?>
<!--Translation by Borja Campina, Edited by Victor Espinoza and Francisco Vila-->
<resources> <resources>
<string name="AppName">Plus Messenger</string> <string name="AppName">Plus Messenger</string>
<string name="AppNameBeta">Telegram Beta</string>
<string name="LanguageName">Español</string> <string name="LanguageName">Español</string>
<string name="LanguageNameInEnglish">Spanish</string> <string name="LanguageNameInEnglish">Spanish</string>
<string name="LanguageCode">es</string> <string name="LanguageCode">es</string>
@ -57,7 +61,28 @@
<string name="MuteDisable">Desactivar</string> <string name="MuteDisable">Desactivar</string>
<string name="Hashtags">HASHTAGS</string> <string name="Hashtags">HASHTAGS</string>
<string name="Recent">RECIENTES</string> <string name="Recent">RECIENTES</string>
<string name="LinkPreview">Vista previa del enlace</string>
<!--channels--> <!--channels-->
<string name="SetAsAdmin">Nombrar como administrador</string>
<string name="DescriptionInfoMega">Puedes poner una descripción para tu grupo.</string>
<string name="LeaveMega">Dejar el grupo</string>
<string name="DeleteMega">Eliminar grupo</string>
<string name="LeaveMegaMenu">Dejar el grupo</string>
<string name="DeleteMegaMenu">Eliminar grupo</string>
<string name="MegaDeleteInfo">Perderás todos los mensajes en este grupo.</string>
<string name="MegaAdminsInfo">Puedes añadir administradores para que te ayuden a dirigir el canal. Mantén pulsado para eliminarlos.</string>
<string name="MegaDeleteAlert">¡Espera! Al eliminar este grupo se quitarán todos los miembros y los mensajes se perderán. ¿Quieres eliminarlo?</string>
<string name="ActionCreateMega">Grupo creado</string>
<string name="MegaAddedBy">un1 te añadió a este grupo</string>
<string name="MegaLeaveAlert">¿Quieres dejar el grupo?</string>
<string name="GroupUserCantAdd">Lo sentimos, no puedes añadir este usuario a grupos.</string>
<string name="GroupUserAddLimit">Lo sentimos, el grupo está lleno.</string>
<string name="GroupUserLeftError">Lo sentimos, este usuario decidió dejar el grupo, así que no puedes invitarlo otra vez.</string>
<string name="GroupUserCantAdmin">Lo sentimos, hay demasiados administradores en el grupo.</string>
<string name="GroupUserCantBot">Lo sentimos, hay demasiados bots en el grupo.</string>
<string name="ActionMigrateFromGroup">Este grupo fue convertido en un supergrupo</string>
<string name="ActionMigrateFromGroupNotify">%1$s fue convertido en un supergrupo</string>
<string name="NoBlockedGroup">Los usuarios bloqueados son expulsados del grupo y sólo pueden volver si son invitados por un administrador. Los enlaces de invitación no funcionan para ellos.</string>
<string name="NewChannel">Nuevo canal</string> <string name="NewChannel">Nuevo canal</string>
<string name="EnterChannelName">Nombre del canal</string> <string name="EnterChannelName">Nombre del canal</string>
<string name="Comments">Comentarios</string> <string name="Comments">Comentarios</string>
@ -94,7 +119,7 @@
<string name="LinkChecking">Verificando nombre...</string> <string name="LinkChecking">Verificando nombre...</string>
<string name="LinkAvailable">%1$s está disponible.</string> <string name="LinkAvailable">%1$s está disponible.</string>
<string name="ChannelMembers">Miembros</string> <string name="ChannelMembers">Miembros</string>
<string name="ChannelBlockedUsers">Usuarios bloqueados</string> <string name="ChannelBlockedUsers">Bloqueados</string>
<string name="ChannelAdministrators">Administradores</string> <string name="ChannelAdministrators">Administradores</string>
<string name="ChannelDelete">Eliminar canal</string> <string name="ChannelDelete">Eliminar canal</string>
<string name="ChannelDeleteMenu">Eliminar canal</string> <string name="ChannelDeleteMenu">Eliminar canal</string>
@ -108,7 +133,6 @@
<string name="ActionChannelChangedPhoto">Foto del canal cambiada</string> <string name="ActionChannelChangedPhoto">Foto del canal cambiada</string>
<string name="ActionChannelRemovedPhoto">Foto del canal eliminada</string> <string name="ActionChannelRemovedPhoto">Foto del canal eliminada</string>
<string name="ActionChannelChangedTitle">Nombre del canal cambiado a un2</string> <string name="ActionChannelChangedTitle">Nombre del canal cambiado a un2</string>
<string name="ActionChannelInvite">un1 te añadió al canal un2</string>
<string name="ChannelPublicLimitReached">Lo sentimos, has creado demasiados canales públicos. Puedes crear un canal privado o eliminar uno de tus canales existentes primero.</string> <string name="ChannelPublicLimitReached">Lo sentimos, has creado demasiados canales públicos. Puedes crear un canal privado o eliminar uno de tus canales existentes primero.</string>
<string name="ChannelModerator">Moderador</string> <string name="ChannelModerator">Moderador</string>
<string name="ChannelCreator">Creador</string> <string name="ChannelCreator">Creador</string>
@ -125,11 +149,11 @@
<string name="ChannelAdminsInfo">Puedes añadir administradores para que te ayuden en el canal. Mantén pulsado para eliminar un administrador.</string> <string name="ChannelAdminsInfo">Puedes añadir administradores para que te ayuden en el canal. Mantén pulsado para eliminar un administrador.</string>
<string name="ChannelJoinTo">¿Quieres unirte al canal \'%1$s\'?</string> <string name="ChannelJoinTo">¿Quieres unirte al canal \'%1$s\'?</string>
<string name="ChannelCantOpenPrivate">Lo sentimos, este canal ya no es accesible.</string> <string name="ChannelCantOpenPrivate">Lo sentimos, este canal ya no es accesible.</string>
<string name="ChannelAddToTitle">¿Añadir a %1$s al canal %2$s?</string>
<string name="ChannelAddTo">¿Añadir a %1$s al canal?</string> <string name="ChannelAddTo">¿Añadir a %1$s al canal?</string>
<string name="ChannelUserLeftError">Lo sentimos, este usuario decidió dejar el grupo, así que no puedes invitarlo otra vez.</string> <string name="ChannelUserLeftError">Lo sentimos, este usuario decidió dejar el canal, así que no puedes invitarlo otra vez.</string>
<string name="ChannelUserCantAdd">Lo sentimos, no puedes añadir a este usuario a canales.</string> <string name="ChannelUserCantAdd">Lo sentimos, no puedes añadir a este usuario a canales.</string>
<string name="ChannelUserCantAdmin">Lo sentimos, hay demasiados administradores en el canal.</string> <string name="ChannelUserCantAdmin">Lo sentimos, hay demasiados administradores en el canal.</string>
<string name="ChannelUserCantBot">Lo sentimos, hay demasiados bots en el canal.</string>
<string name="ChannelUserAddLimit">Lo sentimos, sólo puedes añadir a los primeros 200 miembros a un canal. Sin embargo, una cantidad ilimitada de personas pueden unirse por el enlace del canal.</string> <string name="ChannelUserAddLimit">Lo sentimos, sólo puedes añadir a los primeros 200 miembros a un canal. Sin embargo, una cantidad ilimitada de personas pueden unirse por el enlace del canal.</string>
<string name="ChannelAddedBy">un1 te añadió a este canal</string> <string name="ChannelAddedBy">un1 te añadió a este canal</string>
<string name="ChannelJoined">Te uniste al canal</string> <string name="ChannelJoined">Te uniste al canal</string>
@ -239,6 +263,7 @@
<string name="NobodyLikesSpam2">Lo sentimos, por ahora sólo puedes añadir contactos mutuos a un grupo.</string> <string name="NobodyLikesSpam2">Lo sentimos, por ahora sólo puedes añadir contactos mutuos a un grupo.</string>
<string name="NobodyLikesSpamUrl">https://telegram.org/faq/es#no-puedo-enviar-mensajes-a-quienes-no-son-mis-contactos</string> <string name="NobodyLikesSpamUrl">https://telegram.org/faq/es#no-puedo-enviar-mensajes-a-quienes-no-son-mis-contactos</string>
<string name="MoreInfo">Más información</string> <string name="MoreInfo">Más información</string>
<string name="ShareSendTo">Enviar a...</string>
<!--notification--> <!--notification-->
<string name="MessageLifetimeChanged">%1$s activó la autodestrucción en %2$s</string> <string name="MessageLifetimeChanged">%1$s activó la autodestrucción en %2$s</string>
<string name="MessageLifetimeChangedOutgoing">Activaste la autodestrucción en %1$s</string> <string name="MessageLifetimeChangedOutgoing">Activaste la autodestrucción en %1$s</string>
@ -314,13 +339,22 @@
<string name="CopyLink">Copiar enlace</string> <string name="CopyLink">Copiar enlace</string>
<string name="ShareLink">Compartir enlace</string> <string name="ShareLink">Compartir enlace</string>
<string name="LinkInfo">Cualquiera que tenga Telegram instalada podrá unirse a tu grupo siguiendo este enlace.</string> <string name="LinkInfo">Cualquiera que tenga Telegram instalada podrá unirse a tu grupo siguiendo este enlace.</string>
<!--set admins view-->
<string name="SetAdminsTitle">Administradores</string>
<string name="SetAdminsAll">Todos son administradores</string>
<string name="SetAdminsAllInfo">Todos pueden añadir nuevos miembros, editar el nombre y la foto del grupo.</string>
<string name="SetAdminsNotAllInfo">Sólo los administradores pueden añadir y quitar miembros, editar el nombre y la foto del grupo.</string>
<!--group info view--> <!--group info view-->
<string name="SharedMedia">Multimedia</string> <string name="SharedMedia">Multimedia</string>
<string name="SETTINGS">Ajustes</string> <string name="SETTINGS">Ajustes</string>
<string name="AddMember">Añadir miembro</string> <string name="AddMember">Añadir miembro</string>
<string name="SetAdmins">Nombrar administradores</string>
<string name="DeleteAndExit">Eliminar y dejar el grupo</string> <string name="DeleteAndExit">Eliminar y dejar el grupo</string>
<string name="Notifications">Notificaciones</string> <string name="Notifications">Notificaciones</string>
<string name="KickFromGroup">Expulsar del grupo</string> <string name="KickFromGroup">Expulsar del grupo</string>
<string name="ConvertGroup">Convertir en supergrupo</string>
<string name="ConvertGroupAlert">Por favor, ten en cuenta que los miembros del grupo tendrán que actualizar Telegram a la última versión para ver tu supergrupo. ¿Quieres convertir el grupo?</string>
<string name="ConvertGroupInfo"><![CDATA[<b>]]>Límite de miembros alcanzado.<![CDATA[</b>]]>\n\nPara superar el límite y tener características adicionales, conviértelo en un supergrupo:\n\n• Permiten hasta %1$s\n• Nuevos miembros ven todo el historial\n• Un admin. borra mensajes para todos\n• Notificaciones silenciadas por defecto</string>
<!--contact info view--> <!--contact info view-->
<string name="ShareContact">Compartir</string> <string name="ShareContact">Compartir</string>
<string name="AddContact">Añadir</string> <string name="AddContact">Añadir</string>
@ -674,6 +708,7 @@
<string name="Call">Llamar</string> <string name="Call">Llamar</string>
<string name="Copy">Copiar</string> <string name="Copy">Copiar</string>
<string name="Delete">Eliminar</string> <string name="Delete">Eliminar</string>
<string name="DeleteAndStop">Eliminar y detener</string>
<string name="Forward">Reenviar</string> <string name="Forward">Reenviar</string>
<string name="Retry">Reintentar</string> <string name="Retry">Reintentar</string>
<string name="FromCamera">Desde la cámara</string> <string name="FromCamera">Desde la cámara</string>
@ -728,12 +763,13 @@
<string name="NoHandleAppInstalled">No tienes aplicaciones que puedan manejar el tipo de archivo \'%1$s\'. Por favor, instala una para continuar.</string> <string name="NoHandleAppInstalled">No tienes aplicaciones que puedan manejar el tipo de archivo \'%1$s\'. Por favor, instala una para continuar.</string>
<string name="InviteUser">Este usuario aún no tiene Telegram. ¿Enviarle una invitación?</string> <string name="InviteUser">Este usuario aún no tiene Telegram. ¿Enviarle una invitación?</string>
<string name="AreYouSure">¿Quieres hacerlo?</string> <string name="AreYouSure">¿Quieres hacerlo?</string>
<string name="AddToTheGroupTitle">¿Añadir a %1$s al grupo %2$s?</string> <string name="AddToTheGroupTitle">¿Añadir a %1$s al chat %2$s?</string>
<string name="AddToTheGroupForwardCount">Cantidad de últimos mensajes para reenviar:</string> <string name="AddToTheGroupForwardCount">Cantidad de últimos mensajes para reenviar:</string>
<string name="AddToTheGroup">¿Añadir a %1$s al grupo?</string> <string name="AddToTheGroup">¿Añadir a %1$s al grupo?</string>
<string name="UserAlreadyInGroup">Este usuario ya está en el grupo</string> <string name="UserAlreadyInGroup">Este usuario ya está en el grupo</string>
<string name="ForwardMessagesTo">¿Reenviar mensajes a %1$s?</string> <string name="ForwardMessagesTo">¿Reenviar mensajes a %1$s?</string>
<string name="SendMessagesTo">¿Enviar mensajes a %1$s?</string> <string name="SendMessagesTo">¿Enviar mensajes a %1$s?</string>
<string name="SendContactTo">¿Enviar contacto a %1$s?</string>
<string name="AreYouSureLogout">¿Quieres cerrar sesión?\n\nConsidera que puedes usar Telegram en todos tus dispositivos a la vez.\n\nRecuerda que, al cerrar sesión, eliminas todos tus chats secretos.</string> <string name="AreYouSureLogout">¿Quieres cerrar sesión?\n\nConsidera que puedes usar Telegram en todos tus dispositivos a la vez.\n\nRecuerda que, al cerrar sesión, eliminas todos tus chats secretos.</string>
<string name="AreYouSureSessions">¿Quieres terminar todas las otras sesiones?</string> <string name="AreYouSureSessions">¿Quieres terminar todas las otras sesiones?</string>
<string name="AreYouSureDeleteAndExit">¿Quieres eliminar y dejar el grupo?</string> <string name="AreYouSureDeleteAndExit">¿Quieres eliminar y dejar el grupo?</string>
@ -747,6 +783,7 @@
<string name="AreYouSureClearHistory">¿Quieres eliminar el historial?</string> <string name="AreYouSureClearHistory">¿Quieres eliminar el historial?</string>
<string name="AreYouSureDeleteMessages">¿Quieres eliminar %1$s?</string> <string name="AreYouSureDeleteMessages">¿Quieres eliminar %1$s?</string>
<string name="SendMessagesToGroup">¿Enviar mensajes a %1$s?</string> <string name="SendMessagesToGroup">¿Enviar mensajes a %1$s?</string>
<string name="SendContactToGroup">¿Enviar contacto a %1$s?</string>
<string name="ForwardMessagesToGroup">¿Reenviar mensajes a %1$s?</string> <string name="ForwardMessagesToGroup">¿Reenviar mensajes a %1$s?</string>
<string name="FeatureUnavailable">Lo sentimos, esta característica no está disponible en tu país actualmente.</string> <string name="FeatureUnavailable">Lo sentimos, esta característica no está disponible en tu país actualmente.</string>
<string name="NoUsernameFound">No hay ninguna cuenta de Telegram con este alias.</string> <string name="NoUsernameFound">No hay ninguna cuenta de Telegram con este alias.</string>
@ -973,10 +1010,10 @@
<string name="formatterDay12H">h:mm a</string> <string name="formatterDay12H">h:mm a</string>
<string name="formatDateAtTime">%1$s a las %2$s</string> <string name="formatDateAtTime">%1$s a las %2$s</string>
<!--update text--> <!--update text-->
<string name="updateText">Plus Messenger para Android ha sido actualizada. Novedades en la versión 3.2.6:\n\n- Nuevas animaciones y muchas mejoras visuales\n- Soporte para los nuevos emojis\n- Soporte para Android 6.0 (Now on Tap - Direct Share - Soporte para huella digital en el código de acceso)\n- Otras mejoras y correcciones de errores</string> <string name="updateText">Plus Messenger para Android ha sido actualizada. Novedades en la versión 3.3.1:\n\n- Ahora los grupos pueden tener múltiples administradores, con la habilidad de cambiar la foto de perfil y el nombre del grupo, además de añadir y expulsar miembros.\n- Los grupos que han alcanzado los 200 usuarios, podrán ser convertidos en supergrupos con una capacidad de 1000 miembros.\n- Los canales tienen un nuevo botón para compartir contenidos más rápido, justo al lado de los mensajes.\n\nMás sobre esta actualización:\nhttps://telegram.org/blog/supergroups</string>
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--> <!--Telegram+--><!--
<string name="updatePlusText">\n\nNovedades en 3.2.6.2:\n\n- Cabecera en lista de apps recientes ya toma color de cabecera principal (a partir de lollipop)\n- Tamaño de lista de menciones en pantalla chat aumentado\n- Ahora los canales también se pueden silenciar desde la pantalla principal\n- Añadido mod para ajustar radio de avatar de cabecera en pantalla chat\n- Añadido mod para cambiar color de texto \'escribiendo\' en pantalla chat\n- Corrección de errores</string> <string name="updatePlusText">\n\nNovedades en 3.3.1.0:\n\n- Corrección de errores</string>-->
<string name="TelegramForAndroid">Plus Messenger para Android</string> <string name="TelegramForAndroid">Plus Messenger para Android</string>
<string name="Theming">Tematización</string> <string name="Theming">Tematización</string>
<string name="colorHexInvalid">¡Color hexadecimal inválido!</string> <string name="colorHexInvalid">¡Color hexadecimal inválido!</string>
@ -1042,6 +1079,8 @@
<string name="MuteColor">Color de silencio</string> <string name="MuteColor">Color de silencio</string>
<string name="SendLogs">Enviar logs</string> <string name="SendLogs">Enviar logs</string>
<string name="SendLogsEmpty">No hay logs</string> <string name="SendLogsEmpty">No hay logs</string>
<string name="ClearLogs">Limpiar logs</string>
<string name="ClearLogsMsg">logs borrados</string>
<string name="SendIcon">Icono enviar</string> <string name="SendIcon">Icono enviar</string>
<string name="HideMobile">Ocultar número de teléfono del menú</string> <string name="HideMobile">Ocultar número de teléfono del menú</string>
<string name="FloatingPencilColor">Color de botón lápiz flotante</string> <string name="FloatingPencilColor">Color de botón lápiz flotante</string>
@ -1137,4 +1176,5 @@
<string name="CommandColorCheck">Activar color de comando</string> <string name="CommandColorCheck">Activar color de comando</string>
<string name="CommandColor">Color de comando</string> <string name="CommandColor">Color de comando</string>
<string name="HighlightSearchColor">Color de resaltado de búsqueda</string> <string name="HighlightSearchColor">Color de resaltado de búsqueda</string>
<string name="ThemeUpdated">%s se ha actualizado</string>
</resources> </resources>

View File

@ -108,7 +108,6 @@
<string name="ActionChannelChangedPhoto">Photo de la chaîne modifiée</string> <string name="ActionChannelChangedPhoto">Photo de la chaîne modifiée</string>
<string name="ActionChannelRemovedPhoto">Photo de la chaîne retirée</string> <string name="ActionChannelRemovedPhoto">Photo de la chaîne retirée</string>
<string name="ActionChannelChangedTitle">Nom de la chaîne renommée en un2</string> <string name="ActionChannelChangedTitle">Nom de la chaîne renommée en un2</string>
<string name="ActionChannelInvite">un1 vous a ajouté à la chaine un2</string>
<string name="ChannelPublicLimitReached">Désolé, vous avez crée trop de chaînes publiques. Vous pouvez soit créer une chaîne privée ou supprimer avant une de vos chaînes publiques.</string> <string name="ChannelPublicLimitReached">Désolé, vous avez crée trop de chaînes publiques. Vous pouvez soit créer une chaîne privée ou supprimer avant une de vos chaînes publiques.</string>
<string name="ChannelModerator">Modérateur</string> <string name="ChannelModerator">Modérateur</string>
<string name="ChannelCreator">Créateur</string> <string name="ChannelCreator">Créateur</string>
@ -125,7 +124,6 @@
<string name="ChannelAdminsInfo">Vous pouvez ajouter des administrateurs pour vous aider à gérer votre chaîne. Touchez et maintenez pour retirer des administrateurs.</string> <string name="ChannelAdminsInfo">Vous pouvez ajouter des administrateurs pour vous aider à gérer votre chaîne. Touchez et maintenez pour retirer des administrateurs.</string>
<string name="ChannelJoinTo">Voulez-vous rejoindre la chaîne \'%1$s\'?</string> <string name="ChannelJoinTo">Voulez-vous rejoindre la chaîne \'%1$s\'?</string>
<string name="ChannelCantOpenPrivate">Désolé, ce groupe n\'est plus accessible.</string> <string name="ChannelCantOpenPrivate">Désolé, ce groupe n\'est plus accessible.</string>
<string name="ChannelAddToTitle">Ajouter %1$s à la chaîne %2$s?</string>
<string name="ChannelAddTo">Ajouter %1$s à la chaîne ?</string> <string name="ChannelAddTo">Ajouter %1$s à la chaîne ?</string>
<string name="ChannelUserLeftError">Désolé, %@ a décidé de quitter ce groupe, vous ne pouvez donc plus l\'inviter ici.</string> <string name="ChannelUserLeftError">Désolé, %@ a décidé de quitter ce groupe, vous ne pouvez donc plus l\'inviter ici.</string>
<string name="ChannelUserCantAdd">Désolé, vous ne pouvez pas ajouter cet utilisateur dans des groupes.</string> <string name="ChannelUserCantAdd">Désolé, vous ne pouvez pas ajouter cet utilisateur dans des groupes.</string>
@ -972,9 +970,9 @@
<string name="formatterDay24H">HH:mm</string> <string name="formatterDay24H">HH:mm</string>
<string name="formatterDay12H">h:mm a</string> <string name="formatterDay12H">h:mm a</string>
<string name="formatDateAtTime">%1$s à %2$s</string> <string name="formatDateAtTime">%1$s à %2$s</string>
<!--update text--> <!--update text--><!--
<string name="updateText">Telegram pour Android a été mis à jour. Nouveau dans la version 3.2.6:\n\n- De nouvelles animations et de nombreuses améliorations visuelles.\n- Support pour de nouveaux emoji\n- Autres améliorations et corrections de bogues.</string> <string name="updateText">Telegram pour Android a été mis à jour. Nouveau dans la version 3.2.6:\n\n- De nouvelles animations et de nombreuses améliorations visuelles.\n- Support pour de nouveaux emoji\n- Autres améliorations et corrections de bogues.</string>-->
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--> <!--Telegram+-->
<string name="TelegramForAndroid">Plus Messenger pour Android</string> <string name="TelegramForAndroid">Plus Messenger pour Android</string>
<string name="Theming">Thème</string> <string name="Theming">Thème</string>

View File

@ -109,7 +109,6 @@ e introduce o teu número.</string>
<string name="ActionChannelChangedPhoto">Foto da canle cambiada</string> <string name="ActionChannelChangedPhoto">Foto da canle cambiada</string>
<string name="ActionChannelRemovedPhoto">Foto da canle eliminada</string> <string name="ActionChannelRemovedPhoto">Foto da canle eliminada</string>
<string name="ActionChannelChangedTitle">Nome da canle cambiado a un2</string> <string name="ActionChannelChangedTitle">Nome da canle cambiado a un2</string>
<string name="ActionChannelInvite">un1 engadiute á canle un2</string>
<string name="ChannelPublicLimitReached">Síntoo, creaches demasiadas canles públicas. Podes crear unha canle privada ou eliminar unha das túas canales existentes primeiro.</string> <string name="ChannelPublicLimitReached">Síntoo, creaches demasiadas canles públicas. Podes crear unha canle privada ou eliminar unha das túas canales existentes primeiro.</string>
<string name="ChannelModerator">Moderador</string> <string name="ChannelModerator">Moderador</string>
<string name="ChannelCreator">Creador</string> <string name="ChannelCreator">Creador</string>
@ -126,7 +125,6 @@ e introduce o teu número.</string>
<string name="ChannelAdminsInfo">Podes engadir administradores para que che axuden coa canle. Mantén premido para eliminar un administrador.</string> <string name="ChannelAdminsInfo">Podes engadir administradores para que che axuden coa canle. Mantén premido para eliminar un administrador.</string>
<string name="ChannelJoinTo">Queres unirte á canle \'%1$s\'?</string> <string name="ChannelJoinTo">Queres unirte á canle \'%1$s\'?</string>
<string name="ChannelCantOpenPrivate">Sentímolo, esta canle xa non é accesible.</string> <string name="ChannelCantOpenPrivate">Sentímolo, esta canle xa non é accesible.</string>
<string name="ChannelAddToTitle">Engadir a %1$s á canle %2$s?</string>
<string name="ChannelAddTo">Engadir a %1$s á canle?</string> <string name="ChannelAddTo">Engadir a %1$s á canle?</string>
<string name="ChannelUserLeftError">Sentímolo, este usuario decidiu deixar o grupo, así que non podes volver a invitalo.</string> <string name="ChannelUserLeftError">Sentímolo, este usuario decidiu deixar o grupo, así que non podes volver a invitalo.</string>
<string name="ChannelUserCantAdd">Sentímolo, non podes engadir este usuario a canles.</string> <string name="ChannelUserCantAdd">Sentímolo, non podes engadir este usuario a canles.</string>
@ -973,11 +971,11 @@ e introduce o teu número.</string>
<string name="formatterDay24H">HH:mm</string> <string name="formatterDay24H">HH:mm</string>
<string name="formatterDay12H">h:mm a</string> <string name="formatterDay12H">h:mm a</string>
<string name="formatDateAtTime">%1$s ás %2$s</string> <string name="formatDateAtTime">%1$s ás %2$s</string>
<!--update text--> <!--update text--><!--
<string name="updateText">Telegram para Android foi actualizada. Novidades na versión 3.2.6:\n\n- Novas animacións e moitas melloras visuais\n- Soporte para os novos emoji\n- Outras melloras e correccións de erros</string> <string name="updateText">Telegram para Android foi actualizada. Novidades na versión 3.2.6:\n\n- Novas animacións e moitas melloras visuais\n- Soporte para os novos emoji\n- Outras melloras e correccións de erros</string>-->
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--><!-- <!--Telegram+--><!--
<string name="updatePlusText">\n\nNovidades en 3.2.6.2:\n\n- Engadido mod para a cor do comando na pantalla de conversa\n- Engadido mod para o fondo do contador para conversas/grupos/canles silenciadas na pantalla principal\n- Engadido mod para a cor do resaltado da busca na pantalla principal\n- Corrección de erros</string>--> <string name="updatePlusText">\n\nNovidades en 3.3.1.0:\n\n- Corrección de erros</string>-->
<string name="TelegramForAndroid">Plus Messenger para Android</string> <string name="TelegramForAndroid">Plus Messenger para Android</string>
<string name="Theming">Tematización</string> <string name="Theming">Tematización</string>
<string name="colorHexInvalid">Cor hexadecimal inválida!</string> <string name="colorHexInvalid">Cor hexadecimal inválida!</string>

View File

@ -515,7 +515,7 @@
<string name="formatDateAtTime">%1$s पर %2$s</string> <string name="formatDateAtTime">%1$s पर %2$s</string>
<!--update text--><!-- <!--update text--><!--
<string name="updateText">Plus Messenger for Android has been updated. New in Version 3.0:\n\n\n\n- Dedicated tabs for each one of your custom sticker sets in the sticker panel. Add custom stickers like https://telegram.me/addstickers/Animals\n- New bot API, free for everyone. If you\'re an engineer, create your own bots for games, services or integrations. Learn more at https://telegram.org/blog/bot-revolution\n https://play.google.com/store/apps/details?id=es.rafalense.themes</string>--> <string name="updateText">Plus Messenger for Android has been updated. New in Version 3.0:\n\n\n\n- Dedicated tabs for each one of your custom sticker sets in the sticker panel. Add custom stickers like https://telegram.me/addstickers/Animals\n- New bot API, free for everyone. If you\'re an engineer, create your own bots for games, services or integrations. Learn more at https://telegram.org/blog/bot-revolution\n https://play.google.com/store/apps/details?id=es.rafalense.themes</string>-->
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--><!-- <!--Telegram+--><!--
<string name="updatePlusText"></string>--> <string name="updatePlusText"></string>-->
<string name="TelegramForAndroid">Android के लिए प्लस मैसेंजर</string> <string name="TelegramForAndroid">Android के लिए प्लस मैसेंजर</string>

View File

@ -750,7 +750,7 @@
<string name="formatterDay12H">h:mm a</string> <string name="formatterDay12H">h:mm a</string>
<string name="formatDateAtTime">%1$s u %2$s</string> <string name="formatDateAtTime">%1$s u %2$s</string>
<!--update text--> <!--update text-->
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--> <!--Telegram+-->
<string name="TelegramForAndroid">Plus Messenger za Android</string> <string name="TelegramForAndroid">Plus Messenger za Android</string>
<string name="Theming">Izrada teme</string> <string name="Theming">Izrada teme</string>

View File

@ -1,6 +1,10 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version="1.0" encoding="utf-8"?>
<!--https://www.transifex.com/projects/p/telegram/language/it/members/-->
<resources> <resources>
<string name="AppName">Plus Messenger</string> <string name="AppName">Plus Messenger</string>
<string name="AppNameBeta">Telegram Beta</string>
<string name="LanguageName">Italiano</string> <string name="LanguageName">Italiano</string>
<string name="LanguageNameInEnglish">Italian</string> <string name="LanguageNameInEnglish">Italian</string>
<string name="LanguageCode">it</string> <string name="LanguageCode">it</string>
@ -57,7 +61,28 @@
<string name="MuteDisable">Disabilita</string> <string name="MuteDisable">Disabilita</string>
<string name="Hashtags">HASHTAG</string> <string name="Hashtags">HASHTAG</string>
<string name="Recent">RECENTI</string> <string name="Recent">RECENTI</string>
<string name="LinkPreview">Anteprima link</string>
<!--channels--> <!--channels-->
<string name="SetAsAdmin">Rendi amministratore</string>
<string name="DescriptionInfoMega">Puoi inserire una descrizione opzionale per il tuo gruppo.</string>
<string name="LeaveMega">Lascia il gruppo</string>
<string name="DeleteMega">Elimina gruppo</string>
<string name="LeaveMegaMenu">Lascia il gruppo</string>
<string name="DeleteMegaMenu">Elimina gruppo</string>
<string name="MegaDeleteInfo">Perderai tutti i messaggi in questo gruppo.</string>
<string name="MegaAdminsInfo">Puoi aggiungere amministratori per farti aiutare a gestire il tuo gruppo. Tieni premuto per rimuoverli.</string>
<string name="MegaDeleteAlert">Aspetta! Eliminando il gruppo rimuoverai tutti i membri e tutti i messaggi saranno persi. Vuoi comunque eliminare il gruppo?</string>
<string name="ActionCreateMega">Gruppo creato</string>
<string name="MegaAddedBy">un1 ti ha aggiunto a questo gruppo</string>
<string name="MegaLeaveAlert">Sei sicuro di voler lasciare il gruppo?</string>
<string name="GroupUserCantAdd">Spiacenti, non puoi aggiungere questo utente ai gruppi.</string>
<string name="GroupUserAddLimit">Spiacenti, questo gruppo è pieno.</string>
<string name="GroupUserLeftError">Spiacenti, questo utente ha deciso di lasciare il gruppo, quindi non puoi reinvitarlo.</string>
<string name="GroupUserCantAdmin">Spiacenti, troppi amministratori in questo gruppo.</string>
<string name="GroupUserCantBot">Spiacenti, troppi bot in questo gruppo.</string>
<string name="ActionMigrateFromGroup">Questo gruppo è stato convertito in un supergruppo</string>
<string name="ActionMigrateFromGroupNotify">%1$s è stato convertito in un supergruppo.</string>
<string name="NoBlockedGroup">Gli utenti in lista nera sono rimossi dal gruppo e possono tornare solo se invitati da un amministratore. I link di invito non funzionano per loro.</string>
<string name="NewChannel">Nuovo canale</string> <string name="NewChannel">Nuovo canale</string>
<string name="EnterChannelName">Nome canale</string> <string name="EnterChannelName">Nome canale</string>
<string name="Comments">Commenti</string> <string name="Comments">Commenti</string>
@ -108,7 +133,6 @@
<string name="ActionChannelChangedPhoto">Foto del canale cambiata</string> <string name="ActionChannelChangedPhoto">Foto del canale cambiata</string>
<string name="ActionChannelRemovedPhoto">Foto del canale rimossa</string> <string name="ActionChannelRemovedPhoto">Foto del canale rimossa</string>
<string name="ActionChannelChangedTitle">Nome del canale cambiato in un2</string> <string name="ActionChannelChangedTitle">Nome del canale cambiato in un2</string>
<string name="ActionChannelInvite">un1 ti ha aggiunto al canale un2</string>
<string name="ChannelPublicLimitReached">Spiacenti, hai creato troppi canali pubblici. Puoi creare un canale privato o eliminare un tuo canale pubblico.</string> <string name="ChannelPublicLimitReached">Spiacenti, hai creato troppi canali pubblici. Puoi creare un canale privato o eliminare un tuo canale pubblico.</string>
<string name="ChannelModerator">Moderatore</string> <string name="ChannelModerator">Moderatore</string>
<string name="ChannelCreator">Creatore</string> <string name="ChannelCreator">Creatore</string>
@ -124,12 +148,12 @@
<string name="ChannelLinkInfo">Chiunque abbia Telegram installato sarà in grado di aggiungersi al tuo canale seguendo questo link.</string> <string name="ChannelLinkInfo">Chiunque abbia Telegram installato sarà in grado di aggiungersi al tuo canale seguendo questo link.</string>
<string name="ChannelAdminsInfo">Puoi aggiungere amministratori per farti aiutare a gestire il tuo canale. Tieni premuto per rimuovere gli amministratori.</string> <string name="ChannelAdminsInfo">Puoi aggiungere amministratori per farti aiutare a gestire il tuo canale. Tieni premuto per rimuovere gli amministratori.</string>
<string name="ChannelJoinTo">Vuoi unirti al canale \'%1$s\'?</string> <string name="ChannelJoinTo">Vuoi unirti al canale \'%1$s\'?</string>
<string name="ChannelCantOpenPrivate">Spiacenti, questo canale non è più accessibile.</string> <string name="ChannelCantOpenPrivate">Spiacenti, questa chat non è più accessibile.</string>
<string name="ChannelAddToTitle">Aggiungere %1$s al canale %2$s?</string>
<string name="ChannelAddTo">Aggiungere %1$s al canale?</string> <string name="ChannelAddTo">Aggiungere %1$s al canale?</string>
<string name="ChannelUserLeftError">Spiacenti, questo utente ha deciso di lasciare il gruppo, quindi non puoi reinvitarlo.</string> <string name="ChannelUserLeftError">Spiacenti, questo utente ha deciso di lasciare il canale, quindi non puoi reinvitarlo.</string>
<string name="ChannelUserCantAdd">Spiacenti, non puoi aggiungere questo utente ai canali.</string> <string name="ChannelUserCantAdd">Spiacenti, non puoi aggiungere questo utente ai canali.</string>
<string name="ChannelUserCantAdmin">Spiacenti, troppi amministratori in questo canale.</string> <string name="ChannelUserCantAdmin">Spiacenti, troppi amministratori in questo canale.</string>
<string name="ChannelUserCantBot">Spiacenti, troppi bot in questo canale.</string>
<string name="ChannelUserAddLimit">Spiacenti, puoi aggiungere solo i primi 200 membri a un canale. Ricorda che un numero illimitato di persone potrebbe unirsi tramite il link del canale.</string> <string name="ChannelUserAddLimit">Spiacenti, puoi aggiungere solo i primi 200 membri a un canale. Ricorda che un numero illimitato di persone potrebbe unirsi tramite il link del canale.</string>
<string name="ChannelAddedBy">un1 ti ha aggiunto a questo canale</string> <string name="ChannelAddedBy">un1 ti ha aggiunto a questo canale</string>
<string name="ChannelJoined">Ti sei unito al canale</string> <string name="ChannelJoined">Ti sei unito al canale</string>
@ -239,6 +263,7 @@
<string name="NobodyLikesSpam2">Spiacenti, ma al momento puoi aggiungere ai gruppi solo a contatti in comune.</string> <string name="NobodyLikesSpam2">Spiacenti, ma al momento puoi aggiungere ai gruppi solo a contatti in comune.</string>
<string name="NobodyLikesSpamUrl">https://telegram.org/faq/it#non-posso-inviare-messaggi-a-chi-non-far-parte-dei-miei-contatti</string> <string name="NobodyLikesSpamUrl">https://telegram.org/faq/it#non-posso-inviare-messaggi-a-chi-non-far-parte-dei-miei-contatti</string>
<string name="MoreInfo">Più info</string> <string name="MoreInfo">Più info</string>
<string name="ShareSendTo">Invia a...</string>
<!--notification--> <!--notification-->
<string name="MessageLifetimeChanged">%1$s ha impostato il timer di autodistruzione a %2$s</string> <string name="MessageLifetimeChanged">%1$s ha impostato il timer di autodistruzione a %2$s</string>
<string name="MessageLifetimeChangedOutgoing">Hai impostato il timer di autodistruzione a %1$s</string> <string name="MessageLifetimeChangedOutgoing">Hai impostato il timer di autodistruzione a %1$s</string>
@ -314,13 +339,22 @@
<string name="CopyLink">Copia link</string> <string name="CopyLink">Copia link</string>
<string name="ShareLink">Condividi link</string> <string name="ShareLink">Condividi link</string>
<string name="LinkInfo">Chiunque abbia Telegram installato, sarà in grado di aggiungersi al tuo gruppo aprendo il link.</string> <string name="LinkInfo">Chiunque abbia Telegram installato, sarà in grado di aggiungersi al tuo gruppo aprendo il link.</string>
<!--set admins view-->
<string name="SetAdminsTitle">Amministratori</string>
<string name="SetAdminsAll">Tutti sono amministratori</string>
<string name="SetAdminsAllInfo">Tutti i membri possono aggiungere nuovi membri, modificare nome e foto del gruppo.</string>
<string name="SetAdminsNotAllInfo">Solo gli amministratori possono aggiungere e rimuovere membri e modificare nome e foto del gruppo.</string>
<!--group info view--> <!--group info view-->
<string name="SharedMedia">Media condivisi</string> <string name="SharedMedia">Media condivisi</string>
<string name="SETTINGS">Impostazioni</string> <string name="SETTINGS">Impostazioni</string>
<string name="AddMember">Aggiungi membro</string> <string name="AddMember">Aggiungi membro</string>
<string name="SetAdmins">Imposta amministratori</string>
<string name="DeleteAndExit">Elimina e lascia il gruppo</string> <string name="DeleteAndExit">Elimina e lascia il gruppo</string>
<string name="Notifications">Notifiche</string> <string name="Notifications">Notifiche</string>
<string name="KickFromGroup">Rimuovi dal gruppo</string> <string name="KickFromGroup">Rimuovi dal gruppo</string>
<string name="ConvertGroup">Aggiorna a supergruppo</string>
<string name="ConvertGroupAlert">Per favore ricorda che i membri del gruppo dovranno aggiornare Telegram all\'ultima versione per vedere il tuo supergruppo. Sei sicuro di voler aggiornare questo gruppo?</string>
<string name="ConvertGroupInfo"><![CDATA[<b>]]>Limite di membri raggiunto.<![CDATA[</b>]]>\n\nPer superare il limite ed avere ulteriori funzioni, aggiorna a un supergruppo:\n\n• I supergruppi hanno massimo %1$s\n• I nuovi membri vedono tutta la cronologia\n• Gli amministratori eliminano i messaggi per tutti\n• Le notifiche saranno silenziate di default.</string>
<!--contact info view--> <!--contact info view-->
<string name="ShareContact">Condividi</string> <string name="ShareContact">Condividi</string>
<string name="AddContact">Aggiungi</string> <string name="AddContact">Aggiungi</string>
@ -674,6 +708,7 @@
<string name="Call">Chiama</string> <string name="Call">Chiama</string>
<string name="Copy">Copia</string> <string name="Copy">Copia</string>
<string name="Delete">Elimina</string> <string name="Delete">Elimina</string>
<string name="DeleteAndStop">Elimina e arresta</string>
<string name="Forward">Inoltra</string> <string name="Forward">Inoltra</string>
<string name="Retry">Riprova</string> <string name="Retry">Riprova</string>
<string name="FromCamera">Dalla fotocamera</string> <string name="FromCamera">Dalla fotocamera</string>
@ -728,12 +763,13 @@
<string name="NoHandleAppInstalled">Non hai applicazioni che possono gestire il tipo di file \'%1$s\': installane una per proseguire</string> <string name="NoHandleAppInstalled">Non hai applicazioni che possono gestire il tipo di file \'%1$s\': installane una per proseguire</string>
<string name="InviteUser">Questo utente non ha ancora Telegram, vuoi invitarlo?</string> <string name="InviteUser">Questo utente non ha ancora Telegram, vuoi invitarlo?</string>
<string name="AreYouSure">Sei sicuro?</string> <string name="AreYouSure">Sei sicuro?</string>
<string name="AddToTheGroupTitle">Aggiungere %1$s al gruppo %2$s?</string> <string name="AddToTheGroupTitle">Aggiungere %1$s alla chat %2$s?</string>
<string name="AddToTheGroupForwardCount">Numero di ultimi messaggi da inoltrare:</string> <string name="AddToTheGroupForwardCount">Numero di ultimi messaggi da inoltrare:</string>
<string name="AddToTheGroup">Aggiungere %1$s al gruppo?</string> <string name="AddToTheGroup">Aggiungere %1$s al gruppo?</string>
<string name="UserAlreadyInGroup">Questo utente è già membro del gruppo</string> <string name="UserAlreadyInGroup">Questo utente è già membro del gruppo</string>
<string name="ForwardMessagesTo">Vuoi inoltrare i messaggi a %1$s?</string> <string name="ForwardMessagesTo">Vuoi inoltrare i messaggi a %1$s?</string>
<string name="SendMessagesTo">Inviare i messaggi a %1$s?</string> <string name="SendMessagesTo">Inviare i messaggi a %1$s?</string>
<string name="SendContactTo">Inviare contatto a %1$s?</string>
<string name="AreYouSureLogout">Sei sicuro di volerti disconnettere?\n\nRicorda che puoi usare Telegram su tutti i tuoi dispositivi contemporaneamente.\n\nRicorda, quando ti disconnetti, elimini tutte le Chat Segrete.</string> <string name="AreYouSureLogout">Sei sicuro di volerti disconnettere?\n\nRicorda che puoi usare Telegram su tutti i tuoi dispositivi contemporaneamente.\n\nRicorda, quando ti disconnetti, elimini tutte le Chat Segrete.</string>
<string name="AreYouSureSessions">Terminare tutte le altre sessioni?</string> <string name="AreYouSureSessions">Terminare tutte le altre sessioni?</string>
<string name="AreYouSureDeleteAndExit">Sei sicuro di voler uscire ed eliminare il gruppo?</string> <string name="AreYouSureDeleteAndExit">Sei sicuro di voler uscire ed eliminare il gruppo?</string>
@ -747,6 +783,7 @@
<string name="AreYouSureClearHistory">Sei sicuro di volere eliminare la cronologia?</string> <string name="AreYouSureClearHistory">Sei sicuro di volere eliminare la cronologia?</string>
<string name="AreYouSureDeleteMessages">Sei sicuro di voler eliminare %1$s?</string> <string name="AreYouSureDeleteMessages">Sei sicuro di voler eliminare %1$s?</string>
<string name="SendMessagesToGroup">Inviare messaggi a %1$s?</string> <string name="SendMessagesToGroup">Inviare messaggi a %1$s?</string>
<string name="SendContactToGroup">Inviare contatto a %1$s?</string>
<string name="ForwardMessagesToGroup">Inoltra messaggi a %1$s?</string> <string name="ForwardMessagesToGroup">Inoltra messaggi a %1$s?</string>
<string name="FeatureUnavailable">Spiacenti, questa funzione non è disponibile nel tuo paese.</string> <string name="FeatureUnavailable">Spiacenti, questa funzione non è disponibile nel tuo paese.</string>
<string name="NoUsernameFound">Non esiste alcun account Telegram con questo username.</string> <string name="NoUsernameFound">Non esiste alcun account Telegram con questo username.</string>
@ -973,11 +1010,10 @@
<string name="formatterDay12H">h:mm a</string> <string name="formatterDay12H">h:mm a</string>
<string name="formatDateAtTime">%1$s alle %2$s</string> <string name="formatDateAtTime">%1$s alle %2$s</string>
<!--update text--> <!--update text-->
<string name="updateText">Plus Messenger per Android si è aggiornato. Nuovo nella versione 3.2.6:\n\n- Nuove animazioni e miglioramenti di interfaccia\n- Supporto per le nuove emoji\n- Altri miglioramenti e risoluzione di problemi</string> <string name="updateText">Plus Messenger per Android si è aggiornato. Nuovo nella versione 3.3.1:\n\n- I gruppi ora possono avere più amministratori, con l\'abilità di modificare il nome e l\'immagine, e di aggiungere e rimuovere membri.\n- I gruppi che hanno raggiunto i 200 membri possono ora essere aggiornati a supergruppi e avere fino a 1000 membri.\n- I canali ora hanno un nuovo pulsante di Condivisione Veloce a destra dei messaggi.\n\nPiù info su questo aggiornamento:\nhttps://telegram.org/blog/supergroups</string>
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--><!-- <!--Telegram+--><!--
<string name="updatePlusText"> <string name="updatePlusText">\n\nNovità nella versione 3.3.1.0:\n\n- Correzioni bug</string>-->
\n\nNovità nella versione 3.2.6.2:\n\n- Aggiunta mod per il colore del comando nella schermata della chat\n- Aggiunta mod per il colore dello sfondo del contatore di chat/gruppi/canali mutati nella schermata principale\n- Aggiunta mod per il colore dell\'evidenziazione della ricerca nella schermata principale\n- Correzioni bug</string>-->
<string name="TelegramForAndroid">Plus Messenger per Android</string> <string name="TelegramForAndroid">Plus Messenger per Android</string>
<string name="Theming">Personalizzazione</string> <string name="Theming">Personalizzazione</string>
<string name="colorHexInvalid">Codice del colore esadecimale non valido!</string> <string name="colorHexInvalid">Codice del colore esadecimale non valido!</string>

View File

@ -4,6 +4,7 @@
<resources> <resources>
<string name="AppName">Plus Messenger</string> <string name="AppName">Plus Messenger</string>
<string name="AppNameBeta">텔레그램 베타</string>
<string name="LanguageName">한국어</string> <string name="LanguageName">한국어</string>
<string name="LanguageNameInEnglish">Korean</string> <string name="LanguageNameInEnglish">Korean</string>
<string name="LanguageCode">ko</string> <string name="LanguageCode">ko</string>
@ -60,7 +61,28 @@
<string name="MuteDisable">비활성화</string> <string name="MuteDisable">비활성화</string>
<string name="Hashtags">해시태그</string> <string name="Hashtags">해시태그</string>
<string name="Recent">최신</string> <string name="Recent">최신</string>
<string name="LinkPreview">링크 미리복</string>
<!--channels--> <!--channels-->
<string name="SetAsAdmin">관리자로 지명</string>
<string name="DescriptionInfoMega">그룹에 추가 설명을 제공 할 수 있습니다.</string>
<string name="LeaveMega">그룹 나가기</string>
<string name="DeleteMega">그룹 삭제</string>
<string name="LeaveMegaMenu">그룹 나각</string>
<string name="DeleteMegaMenu">그룹 삭제</string>
<string name="MegaDeleteInfo">그룹에 있는 모든 메시지가 삭제됩니다.</string>
<string name="MegaAdminsInfo">그룹방 관리를 도울 수 있는 관리자를 추가 할 수 있습니다. 길게 탭을하면 관리자 삭제가 가능합니다.</string>
<string name="MegaDeleteAlert">이 그룹방을 삭제하실 경우 모든 구성원과 메시지를 삭제를 하게되며 복구가 안됩니다. 그래도 그룹방을 삭제하시겠습니까?</string>
<string name="ActionCreateMega">그룹 생성됨</string>
<string name="MegaAddedBy">이 그룹방에 un1님이 초대하였습니다.</string>
<string name="MegaLeaveAlert">정말 그룹방에서 나가겠습니까?</string>
<string name="GroupUserCantAdd">죄송합니다, 이 유저를 그룹에 초대할 수 없습니다.</string>
<string name="GroupUserAddLimit">죄송합니다, 그룹방의 인원이 최대치입니다.</string>
<string name="GroupUserLeftError">해당 유저가 스스로 그룹방에서 퇴장을 하여 다시 초대할 수 없습니다.</string>
<string name="GroupUserCantAdmin">죄송합니다, 그룹방에 너무 많은 관리자가 있습니다.</string>
<string name="GroupUserCantBot">죄송합니다, 그룹방에 너무 많은 봇이 있습니다.</string>
<string name="ActionMigrateFromGroup">이 그룹방은 슈퍼그룹방으로 업그레이드 되었습니다.</string>
<string name="ActionMigrateFromGroupNotify">%1$s 그룹방은 슈퍼그룹방으로 업그레이드 되었습니다.</string>
<string name="NoBlockedGroup">그룹방에서 차단되어 퇴장당한 사용자는 관리자가 초대해야지만 그룹방에 입장이 가능합니다.\n초대링크로는 초대가 되지 않습니다.</string>
<string name="NewChannel">새 채널</string> <string name="NewChannel">새 채널</string>
<string name="EnterChannelName">채널명</string> <string name="EnterChannelName">채널명</string>
<string name="Comments">코멘트들</string> <string name="Comments">코멘트들</string>
@ -111,7 +133,6 @@
<string name="ActionChannelChangedPhoto">채널 사진 업데이트됨</string> <string name="ActionChannelChangedPhoto">채널 사진 업데이트됨</string>
<string name="ActionChannelRemovedPhoto">채널 사진 삭제됨</string> <string name="ActionChannelRemovedPhoto">채널 사진 삭제됨</string>
<string name="ActionChannelChangedTitle">채널명이 un2로 변경됨</string> <string name="ActionChannelChangedTitle">채널명이 un2로 변경됨</string>
<string name="ActionChannelInvite">un2채널에 un1님이 초대하였습니다.</string>
<string name="ChannelPublicLimitReached">죄송하지만, 너무 많은 공개 채널을 생성하였습니다. 기존 공개 채널을 삭제하시거나 비공개 채널을 생성할 수 있습니다.</string> <string name="ChannelPublicLimitReached">죄송하지만, 너무 많은 공개 채널을 생성하였습니다. 기존 공개 채널을 삭제하시거나 비공개 채널을 생성할 수 있습니다.</string>
<string name="ChannelModerator">관리자</string> <string name="ChannelModerator">관리자</string>
<string name="ChannelCreator">생성자</string> <string name="ChannelCreator">생성자</string>
@ -127,12 +148,12 @@
<string name="ChannelLinkInfo">텔레그램이 설치된 분들은 링크를 타고 채널에 참여가 가능합니다.</string> <string name="ChannelLinkInfo">텔레그램이 설치된 분들은 링크를 타고 채널에 참여가 가능합니다.</string>
<string name="ChannelAdminsInfo">채널 관리를 도울 수 있는 관리자를 추가 할 수 있습니다. 길게 탭을하면 관리자 삭제가 가능합니다.</string> <string name="ChannelAdminsInfo">채널 관리를 도울 수 있는 관리자를 추가 할 수 있습니다. 길게 탭을하면 관리자 삭제가 가능합니다.</string>
<string name="ChannelJoinTo">\'%1$s\'채널에 참여하시겠습니까?</string> <string name="ChannelJoinTo">\'%1$s\'채널에 참여하시겠습니까?</string>
<string name="ChannelCantOpenPrivate">죄송합니다, 이 채널은 더 이상 접근이 불가능 합니다.</string> <string name="ChannelCantOpenPrivate">죄송합니다, 이 채팅방에 더 이상 접근이 불가능 합니다.</string>
<string name="ChannelAddToTitle">%2$s 채널에 %1$s님을 추가할까요?</string>
<string name="ChannelAddTo">%1$s 님을 이 채널에 추가할까요</string> <string name="ChannelAddTo">%1$s 님을 이 채널에 추가할까요</string>
<string name="ChannelUserLeftError">해당 유저가 스스로 채널에서 퇴장을 하여 다시 초대할 수 없습니다.</string> <string name="ChannelUserLeftError">해당 사용자가 스스로 채널에서 퇴장을 하여 다시 초대할 수 없습니다.</string>
<string name="ChannelUserCantAdd">죄송합니다, 이 유저를 채널에 추가 할 수 없습니다.</string> <string name="ChannelUserCantAdd">죄송합니다, 이 유저를 채널에 추가 할 수 없습니다.</string>
<string name="ChannelUserCantAdmin">죄송합니다, 채널에 너무 많은 관리자가 있습니다.</string> <string name="ChannelUserCantAdmin">죄송합니다, 채널에 너무 많은 관리자가 있습니다.</string>
<string name="ChannelUserCantBot">죄송합니다, 채널에 너무 많은 봇이 있습니다.</string>
<string name="ChannelUserAddLimit">죄송합니다, 채널에는 첫 200명까지만 초대가 가능합니다. 채널 링크를 통하여 무제한 입장이 가능합니다.</string> <string name="ChannelUserAddLimit">죄송합니다, 채널에는 첫 200명까지만 초대가 가능합니다. 채널 링크를 통하여 무제한 입장이 가능합니다.</string>
<string name="ChannelAddedBy">이 채널에 un1님이 초대하였습니다.</string> <string name="ChannelAddedBy">이 채널에 un1님이 초대하였습니다.</string>
<string name="ChannelJoined">채널에 참여하였습니다.</string> <string name="ChannelJoined">채널에 참여하였습니다.</string>
@ -217,7 +238,7 @@
<string name="EncryptedDescription2">서버에 어떤 흔적도 남기지 않습니다</string> <string name="EncryptedDescription2">서버에 어떤 흔적도 남기지 않습니다</string>
<string name="EncryptedDescription3">일정 시간 후에 자동삭제가 가능합니다</string> <string name="EncryptedDescription3">일정 시간 후에 자동삭제가 가능합니다</string>
<string name="EncryptedDescription4">전달 기능이 허용되지 않습니다</string> <string name="EncryptedDescription4">전달 기능이 허용되지 않습니다</string>
<string name="YouWereKicked">그룹에서 추방되었습니다</string> <string name="YouWereKicked">그룹에서 퇴장당했습니다.</string>
<string name="YouLeft">그룹을 떠났습니다</string> <string name="YouLeft">그룹을 떠났습니다</string>
<string name="DeleteThisGroup">이 그룹 삭제</string> <string name="DeleteThisGroup">이 그룹 삭제</string>
<string name="DeleteThisChat">이 채팅방 삭제</string> <string name="DeleteThisChat">이 채팅방 삭제</string>
@ -242,6 +263,7 @@
<string name="NobodyLikesSpam2">죄송합니다, 서로 연락처가 추가된 경우에만 그룹에 구성원을 추가 할 수 있습니다.</string> <string name="NobodyLikesSpam2">죄송합니다, 서로 연락처가 추가된 경우에만 그룹에 구성원을 추가 할 수 있습니다.</string>
<string name="NobodyLikesSpamUrl">https://telegram.org/faq#can-39t-send-messages-to-non-contacts</string> <string name="NobodyLikesSpamUrl">https://telegram.org/faq#can-39t-send-messages-to-non-contacts</string>
<string name="MoreInfo">더 보기</string> <string name="MoreInfo">더 보기</string>
<string name="ShareSendTo">다음에게 보내기..</string>
<!--notification--> <!--notification-->
<string name="MessageLifetimeChanged">%1$s님이 자동삭제를 %2$s 후로 설정했습니다</string> <string name="MessageLifetimeChanged">%1$s님이 자동삭제를 %2$s 후로 설정했습니다</string>
<string name="MessageLifetimeChangedOutgoing">자동삭제를 %1$s 후로 설정했습니다</string> <string name="MessageLifetimeChangedOutgoing">자동삭제를 %1$s 후로 설정했습니다</string>
@ -271,8 +293,8 @@
<string name="NotificationEditedGroupPhoto">%1$s님이 %2$s 그룹 사진을 변경했습니다</string> <string name="NotificationEditedGroupPhoto">%1$s님이 %2$s 그룹 사진을 변경했습니다</string>
<string name="NotificationGroupAddMember">%1$s님이 %3$s님을 %2$s 그룹에 초대했습니다</string> <string name="NotificationGroupAddMember">%1$s님이 %3$s님을 %2$s 그룹에 초대했습니다</string>
<string name="NotificationGroupAddSelf">%1$s 님이 %2$s 그룹으로 되돌아왔습니다</string> <string name="NotificationGroupAddSelf">%1$s 님이 %2$s 그룹으로 되돌아왔습니다</string>
<string name="NotificationGroupKickMember">%1$s님이 %3$s님을 %2$s 그룹에서 추방했습니다</string> <string name="NotificationGroupKickMember">%1$s님이 %3$s님을 %2$s 그룹에서 퇴장당했습니다.</string>
<string name="NotificationGroupKickYou">%1$s님이 %2$s 그룹에서 추방했습니다</string> <string name="NotificationGroupKickYou">%1$s님이 %2$s 그룹에서 퇴장당했습니다.</string>
<string name="NotificationGroupLeftMember">%1$s님이 %2$s 그룹을 떠났습니다</string> <string name="NotificationGroupLeftMember">%1$s님이 %2$s 그룹을 떠났습니다</string>
<string name="NotificationContactJoined">%1$s님이 텔레그램에 가입했습니다!</string> <string name="NotificationContactJoined">%1$s님이 텔레그램에 가입했습니다!</string>
<string name="NotificationUnrecognizedDevice">%1$s님,\n%2$s에 새 기기에서 회원님의 계정 로그인이 감지되었습니다. \n\n기기: %3$s\n위치: %4$s\n\n본인의 접속이 아니라면 \'설정\' 창에서 \'모든 세션 종료\' 기능을 실행하세요.\n\n만약 강제접속 의심이 되신다면 2단계 인증을 설정 - 개인정보 및 보안에서 설정할 수 있습니다.\n\n감사합니다.\n텔레그램 팀</string> <string name="NotificationUnrecognizedDevice">%1$s님,\n%2$s에 새 기기에서 회원님의 계정 로그인이 감지되었습니다. \n\n기기: %3$s\n위치: %4$s\n\n본인의 접속이 아니라면 \'설정\' 창에서 \'모든 세션 종료\' 기능을 실행하세요.\n\n만약 강제접속 의심이 되신다면 2단계 인증을 설정 - 개인정보 및 보안에서 설정할 수 있습니다.\n\n감사합니다.\n텔레그램 팀</string>
@ -317,13 +339,22 @@
<string name="CopyLink">링크 복사</string> <string name="CopyLink">링크 복사</string>
<string name="ShareLink">링크 공유</string> <string name="ShareLink">링크 공유</string>
<string name="LinkInfo">텔레그램이 설치된 분들은 링크를 타고 그룹방에 참여가 가능합니다.</string> <string name="LinkInfo">텔레그램이 설치된 분들은 링크를 타고 그룹방에 참여가 가능합니다.</string>
<!--set admins view-->
<string name="SetAdminsTitle">관리자 대화</string>
<string name="SetAdminsAll">모든 구성원이 관리자입니다.</string>
<string name="SetAdminsAllInfo">그룹에 있는 모든 구성원은 상대 초대, 이름 및 사진을 수정할 수 있습니다.</string>
<string name="SetAdminsNotAllInfo">그룹방에 있는 관리자만 구성원을 초대, 퇴장, 이름 편집 및 사진 수정할 수 있습니다.</string>
<!--group info view--> <!--group info view-->
<string name="SharedMedia">공유한 미디어</string> <string name="SharedMedia">공유한 미디어</string>
<string name="SETTINGS">설정</string> <string name="SETTINGS">설정</string>
<string name="AddMember">대화상대 추가</string> <string name="AddMember">대화상대 추가</string>
<string name="SetAdmins">관리자 설정</string>
<string name="DeleteAndExit">그룹에서 나가기</string> <string name="DeleteAndExit">그룹에서 나가기</string>
<string name="Notifications">알림</string> <string name="Notifications">알림</string>
<string name="KickFromGroup">그룹에서 내보내기</string> <string name="KickFromGroup">그룹에서 내보내기</string>
<string name="ConvertGroup">슈퍼그룹방으로 업그레이드하기</string>
<string name="ConvertGroupAlert">슈퍼그룹방을 보려면 구성원들이 최신 텔레그램 버전으로 업데이트 해야합니다. 저암ㄹ로 그룹방을 업그레이드 하시겠습니까?</string>
<string name="ConvertGroupInfo"><![CDATA[<b>]]>구성원이 최대치입니다.<![CDATA[</b>]]>\n\n추가 기능 및 더 많은 구성원을 추가하려면 슈퍼그룹방으로 업그레이드하세요:\n\n• 슈퍼그룹방은 %1$s명까지 초대가능합니다.\n• 새로운 구성원은 모든 대화내역을 볼 수 있습니다.\n• 관리자는 모두에게 메시지 삭제를 할 수 있습니다.\n• 기본값으로 알림이 음소거 됩니다.</string>
<!--contact info view--> <!--contact info view-->
<string name="ShareContact">공유</string> <string name="ShareContact">공유</string>
<string name="AddContact">추가</string> <string name="AddContact">추가</string>
@ -677,6 +708,7 @@
<string name="Call">전화 걸기</string> <string name="Call">전화 걸기</string>
<string name="Copy">복사</string> <string name="Copy">복사</string>
<string name="Delete">삭제</string> <string name="Delete">삭제</string>
<string name="DeleteAndStop">삭제 및 정지</string>
<string name="Forward">전달</string> <string name="Forward">전달</string>
<string name="Retry">재전송</string> <string name="Retry">재전송</string>
<string name="FromCamera">사진 촬영</string> <string name="FromCamera">사진 촬영</string>
@ -688,21 +720,21 @@
<!--messages--> <!--messages-->
<string name="ActionInviteYou">초대링크를 타고 그룹에 참여하였습니다.</string> <string name="ActionInviteYou">초대링크를 타고 그룹에 참여하였습니다.</string>
<string name="ActionInviteUser">초대링크를 타고 그룹에 un1님이 참여하였습니다.</string> <string name="ActionInviteUser">초대링크를 타고 그룹에 un1님이 참여하였습니다.</string>
<string name="ActionKickUser">un1님이 un2님을 추방했습니다</string> <string name="ActionKickUser">un1님이 un2님을 퇴장시켰습니다.</string>
<string name="ActionLeftUser">un1님이 퇴장했습니다</string> <string name="ActionLeftUser">un1님이 퇴장했습니다</string>
<string name="ActionAddUser">un1님이 un2님을 초대했습니다</string> <string name="ActionAddUser">un1님이 un2님을 초대했습니다</string>
<string name="ActionRemovedPhoto">un1님이 그룹 사진을 삭제했습니다</string> <string name="ActionRemovedPhoto">un1님이 그룹 사진을 삭제했습니다</string>
<string name="ActionChangedPhoto">un1님이 그룹 사진을 변경했습니다</string> <string name="ActionChangedPhoto">un1님이 그룹 사진을 변경했습니다</string>
<string name="ActionChangedTitle">un1님이 그룹 이름을 un2 그룹으로 변경했습니다</string> <string name="ActionChangedTitle">un1님이 그룹 이름을 un2 그룹으로 변경했습니다</string>
<string name="ActionCreateGroup">un1님이 그룹을 만들었습니다</string> <string name="ActionCreateGroup">un1님이 그룹을 만들었습니다</string>
<string name="ActionYouKickUser">un2님을 추방했습니다</string> <string name="ActionYouKickUser">un2님을 퇴장시켰습니다.</string>
<string name="ActionYouLeftUser">그룹을 떠났습니다</string> <string name="ActionYouLeftUser">그룹을 떠났습니다</string>
<string name="ActionYouAddUser">un2님을 초대했습니다</string> <string name="ActionYouAddUser">un2님을 초대했습니다</string>
<string name="ActionYouRemovedPhoto">그룹 사진을 삭제했습니다</string> <string name="ActionYouRemovedPhoto">그룹 사진을 삭제했습니다</string>
<string name="ActionYouChangedPhoto">그룹 사진을 변경했습니다</string> <string name="ActionYouChangedPhoto">그룹 사진을 변경했습니다</string>
<string name="ActionYouChangedTitle">그룹 이름을 un2 그룹으로 변경했습니다</string> <string name="ActionYouChangedTitle">그룹 이름을 un2 그룹으로 변경했습니다</string>
<string name="ActionYouCreateGroup">그룹을 만들었습니다</string> <string name="ActionYouCreateGroup">그룹을 만들었습니다</string>
<string name="ActionKickUserYou">un1님이 추방했습니다</string> <string name="ActionKickUserYou">un1님이 퇴장당했습니다.</string>
<string name="ActionAddUserYou">un1님이 그룹에 초대했습니다</string> <string name="ActionAddUserYou">un1님이 그룹에 초대했습니다</string>
<string name="ActionAddUserSelf">un1 님께서 그룹에 돌아오셨습니다</string> <string name="ActionAddUserSelf">un1 님께서 그룹에 돌아오셨습니다</string>
<string name="ActionAddUserSelfYou">그룹에 돌아오셨습니다.</string> <string name="ActionAddUserSelfYou">그룹에 돌아오셨습니다.</string>
@ -731,12 +763,13 @@
<string name="NoHandleAppInstalled">\'%1$s\' 파일 형식을 처리할 앱이 없습니다. 계속하려면 앱을 설치해 주세요.</string> <string name="NoHandleAppInstalled">\'%1$s\' 파일 형식을 처리할 앱이 없습니다. 계속하려면 앱을 설치해 주세요.</string>
<string name="InviteUser">친구가 아직 텔레그램을 사용하지 않네요. 초대해 보세요!</string> <string name="InviteUser">친구가 아직 텔레그램을 사용하지 않네요. 초대해 보세요!</string>
<string name="AreYouSure">확실합니까?</string> <string name="AreYouSure">확실합니까?</string>
<string name="AddToTheGroupTitle">%2$s 그룹에 %1$s님을 추가할까요?</string> <string name="AddToTheGroupTitle">%2$s 채팅방에 %1$s님을 추가할까요?</string>
<string name="AddToTheGroupForwardCount">전달할 마지막 대화내용 개수:</string> <string name="AddToTheGroupForwardCount">전달할 마지막 대화내용 개수:</string>
<string name="AddToTheGroup">%1$s 님을 그룹에 추가할까요?</string> <string name="AddToTheGroup">%1$s 님을 그룹에 추가할까요?</string>
<string name="UserAlreadyInGroup">이 사용자는 이미 그룹에 추가되었습니다.</string> <string name="UserAlreadyInGroup">이 사용자는 이미 그룹에 추가되었습니다.</string>
<string name="ForwardMessagesTo">%1$s님에게 메시지를 전달할까요?</string> <string name="ForwardMessagesTo">%1$s님에게 메시지를 전달할까요?</string>
<string name="SendMessagesTo">%1$s님에게 메시지를 보낼까요?</string> <string name="SendMessagesTo">%1$s님에게 메시지를 보낼까요?</string>
<string name="SendContactTo">%1$s에게 연락처를 보내시겠습니까?</string>
<string name="AreYouSureLogout">정말로 로그아웃하시겠습니까?\n\n텔레그램은 여러 기기에서 동시에 사용이 가능합니다.\n\n로그아웃하시면 비밀대화가 삭제되는 점 유의해주세요.</string> <string name="AreYouSureLogout">정말로 로그아웃하시겠습니까?\n\n텔레그램은 여러 기기에서 동시에 사용이 가능합니다.\n\n로그아웃하시면 비밀대화가 삭제되는 점 유의해주세요.</string>
<string name="AreYouSureSessions">현재 기기를 제외하고 다른 기기에 로그인된 세션을 모두 종료시킬까요?</string> <string name="AreYouSureSessions">현재 기기를 제외하고 다른 기기에 로그인된 세션을 모두 종료시킬까요?</string>
<string name="AreYouSureDeleteAndExit">그룹에서 나갈까요?</string> <string name="AreYouSureDeleteAndExit">그룹에서 나갈까요?</string>
@ -750,6 +783,7 @@
<string name="AreYouSureClearHistory">정말로 대화내용을 지우시겠습니까?</string> <string name="AreYouSureClearHistory">정말로 대화내용을 지우시겠습니까?</string>
<string name="AreYouSureDeleteMessages">%1$s: 정말로 삭제하시겠습니까?</string> <string name="AreYouSureDeleteMessages">%1$s: 정말로 삭제하시겠습니까?</string>
<string name="SendMessagesToGroup">%1$s 그룹에 메시지를 보낼까요?</string> <string name="SendMessagesToGroup">%1$s 그룹에 메시지를 보낼까요?</string>
<string name="SendContactToGroup">%1$s에게 연락처를 보내시겠습니까?</string>
<string name="ForwardMessagesToGroup">%1$s 그룹에 메시지를 전달할까요?</string> <string name="ForwardMessagesToGroup">%1$s 그룹에 메시지를 전달할까요?</string>
<string name="FeatureUnavailable">이 기능은 회원님의 국가에서는 사용할 수 없습니다.</string> <string name="FeatureUnavailable">이 기능은 회원님의 국가에서는 사용할 수 없습니다.</string>
<string name="NoUsernameFound">입력된 아이디와 일치하는 텔레그램 계정이 없습니다.</string> <string name="NoUsernameFound">입력된 아이디와 일치하는 텔레그램 계정이 없습니다.</string>
@ -976,6 +1010,6 @@
<string name="formatterDay12H">a h:mm</string> <string name="formatterDay12H">a h:mm</string>
<string name="formatDateAtTime">%1$s %2$s</string> <string name="formatDateAtTime">%1$s %2$s</string>
<!--update text--> <!--update text-->
<string name="updateText">텔레그램 안드로이드 버전이 업데이트 되었습니다. 새로운 버전은 3.2.6 입니다:\n\n- 새로운 애니메이션 및 다양한 비쥬얼 향상\n- 신규 이모티콘 지원\n- 기타 기능 향상 및 버그 수정</string> <string name="updateText">텔레그램 안드로이드 버전이 업데이트 되었습니다. 새로운 버전은 3.3.1 입니다:\n\n- 그룹방제목, 그룹방사진, 구성원 추가 및 삭제등을 할 수 있는 복수의 그룹 관리자 설정 가능\n- 200명 제한이 걸린 그룹은 1,000명까지 활용가능한 슈퍼그룹으로 업그레이드 가능\n\n슈퍼그룹 및 업데이트 관련 내용 :\nhttps://telegram.org/blog/supergroups</string>
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
</resources> </resources>

View File

@ -1,6 +1,10 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version="1.0" encoding="utf-8"?>
<!--https://www.transifex.com/projects/p/telegram/language/nl/members/-->
<resources> <resources>
<string name="AppName">Plus Messenger</string> <string name="AppName">Plus Messenger</string>
<string name="AppNameBeta">Telegram Bèta</string>
<string name="LanguageName">Nederlands</string> <string name="LanguageName">Nederlands</string>
<string name="LanguageNameInEnglish">Dutch</string> <string name="LanguageNameInEnglish">Dutch</string>
<string name="LanguageCode">nl</string> <string name="LanguageCode">nl</string>
@ -57,7 +61,28 @@
<string name="MuteDisable">Uitschakelen</string> <string name="MuteDisable">Uitschakelen</string>
<string name="Hashtags">HASHTAGS</string> <string name="Hashtags">HASHTAGS</string>
<string name="Recent">RECENT</string> <string name="Recent">RECENT</string>
<string name="LinkPreview">Link-voorvertoning</string>
<!--channels--> <!--channels-->
<string name="SetAsAdmin">Promoveren tot beheerder</string>
<string name="DescriptionInfoMega">Optioneel kun je een groepsbeschrijving geven.</string>
<string name="LeaveMega">Groep verlaten</string>
<string name="DeleteMega">Groep verwijderen</string>
<string name="LeaveMegaMenu">Groep verlaten</string>
<string name="DeleteMegaMenu">Groep verwijderen</string>
<string name="MegaDeleteInfo">Je raakt alle berichten in deze groep kwijt.</string>
<string name="MegaAdminsInfo">Je kunt beheerders toevoegen om je te helpen je groep te beheren. Druk en houd ingedrukt om beheerders te verwijderen.</string>
<string name="MegaDeleteAlert">Groep echt verwijderen? Berichten worden gewist en alle deelnemers verwijderd.</string>
<string name="ActionCreateMega">Groep gemaakt</string>
<string name="MegaAddedBy">un1 heeft je toegevoegd aan deze groep</string>
<string name="MegaLeaveAlert">Groep echt verlaten?</string>
<string name="GroupUserCantAdd">Je kunt deze gebruiker niet toevoegen aan groepen.</string>
<string name="GroupUserAddLimit">Sorry, deze groep is vol.</string>
<string name="GroupUserLeftError">Deze gebruiker heeft de groep verlaten. Je kunt hem/haar niet meer uitnodigen.</string>
<string name="GroupUserCantAdmin">Maximaal aantal beheerders bereikt.</string>
<string name="GroupUserCantBot">Maximaal aantal bots bereikt.</string>
<string name="ActionMigrateFromGroup">De groep is omgezet naar een supergroep</string>
<string name="ActionMigrateFromGroupNotify">%1$s is omgezet naar een supergroep</string>
<string name="NoBlockedGroup">Geblokkeerde gebruikers kunnen alleen worden uitgenodigd door beheerders, uitnodigingslinks werken niet voor hen.</string>
<string name="NewChannel">Nieuw kanaal</string> <string name="NewChannel">Nieuw kanaal</string>
<string name="EnterChannelName">Kanaalnaam</string> <string name="EnterChannelName">Kanaalnaam</string>
<string name="Comments">Reacties</string> <string name="Comments">Reacties</string>
@ -108,7 +133,6 @@
<string name="ActionChannelChangedPhoto">Kanaalfoto bijgewerkt</string> <string name="ActionChannelChangedPhoto">Kanaalfoto bijgewerkt</string>
<string name="ActionChannelRemovedPhoto">Kanaalfoto verwijderd</string> <string name="ActionChannelRemovedPhoto">Kanaalfoto verwijderd</string>
<string name="ActionChannelChangedTitle">Kanaalnaam gewijzigd naar un2</string> <string name="ActionChannelChangedTitle">Kanaalnaam gewijzigd naar un2</string>
<string name="ActionChannelInvite">un1 heeft je toegevoegd aan het kanaal un2</string>
<string name="ChannelPublicLimitReached">Het maximale aantal publieke kanalen is bereikt. Je kunt een privé-kanaal maken of een kanaal verwijderen om een nieuwe te maken.</string> <string name="ChannelPublicLimitReached">Het maximale aantal publieke kanalen is bereikt. Je kunt een privé-kanaal maken of een kanaal verwijderen om een nieuwe te maken.</string>
<string name="ChannelModerator">Moderator</string> <string name="ChannelModerator">Moderator</string>
<string name="ChannelCreator">Maker</string> <string name="ChannelCreator">Maker</string>
@ -124,12 +148,12 @@
<string name="ChannelLinkInfo">Andere Telegram-gebruikers kunnen aan je groep deelnemen door deze link te openen.</string> <string name="ChannelLinkInfo">Andere Telegram-gebruikers kunnen aan je groep deelnemen door deze link te openen.</string>
<string name="ChannelAdminsInfo">Je kunt beheerders toevoegen om je te helpen je kanaal te beheren. Druk en houd ingedrukt om beheerders te verwijderen.</string> <string name="ChannelAdminsInfo">Je kunt beheerders toevoegen om je te helpen je kanaal te beheren. Druk en houd ingedrukt om beheerders te verwijderen.</string>
<string name="ChannelJoinTo">Deelnemen aan kanaal \'%1$s\'?</string> <string name="ChannelJoinTo">Deelnemen aan kanaal \'%1$s\'?</string>
<string name="ChannelCantOpenPrivate">Sorry, dit kanaal is niet beschikbaar.</string> <string name="ChannelCantOpenPrivate">Sorry, deze chat is niet beschikbaar.</string>
<string name="ChannelAddToTitle">%1$s toevoegen aan het kanaal %2$s?</string>
<string name="ChannelAddTo">%1$s toevoegen aan het kanaal?</string> <string name="ChannelAddTo">%1$s toevoegen aan het kanaal?</string>
<string name="ChannelUserLeftError">Deze gebruiker heeft de groep verlaten. Je kunt hem/haar niet meer uitnodigen.</string> <string name="ChannelUserLeftError">Deze gebruiker heeft het kanaal verlaten. Je kunt hem/haar niet meer uitnodigen.</string>
<string name="ChannelUserCantAdd">Je kunt deze gebruiker niet toevoegen aan kanalen.</string> <string name="ChannelUserCantAdd">Je kunt deze gebruiker niet toevoegen aan kanalen.</string>
<string name="ChannelUserCantAdmin">Maximaal aantal administrators bereikt.</string> <string name="ChannelUserCantAdmin">Maximaal aantal beheerders bereikt.</string>
<string name="ChannelUserCantBot">Maximaal aantal bots bereikt.</string>
<string name="ChannelUserAddLimit">Je kunt 200 deelnemers handmatig toevoegen aan een kanaal. Een ongelimiteerd aantal mensen kan deelnemen via de link van het kanaal.</string> <string name="ChannelUserAddLimit">Je kunt 200 deelnemers handmatig toevoegen aan een kanaal. Een ongelimiteerd aantal mensen kan deelnemen via de link van het kanaal.</string>
<string name="ChannelAddedBy">un1 heeft je toegevoegd aan dit kanaal</string> <string name="ChannelAddedBy">un1 heeft je toegevoegd aan dit kanaal</string>
<string name="ChannelJoined">Je neemt deel aan het kanaal</string> <string name="ChannelJoined">Je neemt deel aan het kanaal</string>
@ -239,6 +263,7 @@
<string name="NobodyLikesSpam2">Je kunt momenteel alleen onderlinge contacten aan groepen toevoegen</string> <string name="NobodyLikesSpam2">Je kunt momenteel alleen onderlinge contacten aan groepen toevoegen</string>
<string name="NobodyLikesSpamUrl">https://telegram.org/faq#can-39t-send-messages-to-non-contacts</string> <string name="NobodyLikesSpamUrl">https://telegram.org/faq#can-39t-send-messages-to-non-contacts</string>
<string name="MoreInfo">Meer informatie</string> <string name="MoreInfo">Meer informatie</string>
<string name="ShareSendTo">Versturen naar...</string>
<!--notification--> <!--notification-->
<string name="MessageLifetimeChanged">%1$s heeft de zelfvernietigingstimer ingesteld op %2$s</string> <string name="MessageLifetimeChanged">%1$s heeft de zelfvernietigingstimer ingesteld op %2$s</string>
<string name="MessageLifetimeChangedOutgoing">Je hebt de zelfvernietigingstimer ingesteld op %1$s</string> <string name="MessageLifetimeChangedOutgoing">Je hebt de zelfvernietigingstimer ingesteld op %1$s</string>
@ -314,13 +339,22 @@
<string name="CopyLink">Link kopiëren</string> <string name="CopyLink">Link kopiëren</string>
<string name="ShareLink">Link delen</string> <string name="ShareLink">Link delen</string>
<string name="LinkInfo">Andere Telegram-gebruikers kunnen aan je groep deelnemen door deze link te openen.</string> <string name="LinkInfo">Andere Telegram-gebruikers kunnen aan je groep deelnemen door deze link te openen.</string>
<!--set admins view-->
<string name="SetAdminsTitle">Beheerders</string>
<string name="SetAdminsAll">Iedereen is beheerder</string>
<string name="SetAdminsAllInfo">Iedereen mag deelnemers toevoegen en de groepsfoto of naam wijzigen.</string>
<string name="SetAdminsNotAllInfo">Beheerders mogen deelnemers beheren en de groepsfoto of naam wijzigen.</string>
<!--group info view--> <!--group info view-->
<string name="SharedMedia">Gedeelde media</string> <string name="SharedMedia">Gedeelde media</string>
<string name="SETTINGS">Instellingen</string> <string name="SETTINGS">Instellingen</string>
<string name="AddMember">Deelnemer toevoegen</string> <string name="AddMember">Deelnemer toevoegen</string>
<string name="SetAdmins">Beheerders instellen</string>
<string name="DeleteAndExit">Groep verwijderen en verlaten</string> <string name="DeleteAndExit">Groep verwijderen en verlaten</string>
<string name="Notifications">Meldingen</string> <string name="Notifications">Meldingen</string>
<string name="KickFromGroup">Verwijderen uit groep</string> <string name="KickFromGroup">Verwijderen uit groep</string>
<string name="ConvertGroup">Upgraden naar supergroep</string>
<string name="ConvertGroupAlert">Groepsdeelnemers moeten updaten naar de meest recente Telegram om je supergroep te kunnen zien. Groep echt upgraden?</string>
<string name="ConvertGroupInfo"><![CDATA[<b>]]>Deelnemerslimiet bereikt.<![CDATA[</b>]]>\n\nWil je extra functies en een hogere limiet? Upgrade naar een supergroep:\n\n• Supergroepen hebben tot %1$s\n• Nieuwe leden zien de hele geschiedenis\n• Beheerder wist berichten voor iedereen\n• Meldingen staan standaard uit</string>
<!--contact info view--> <!--contact info view-->
<string name="ShareContact">Delen</string> <string name="ShareContact">Delen</string>
<string name="AddContact">Toevoegen</string> <string name="AddContact">Toevoegen</string>
@ -674,6 +708,7 @@
<string name="Call">Bellen</string> <string name="Call">Bellen</string>
<string name="Copy">Kopieer</string> <string name="Copy">Kopieer</string>
<string name="Delete">Verwijder</string> <string name="Delete">Verwijder</string>
<string name="DeleteAndStop">Verwijderen en stoppen</string>
<string name="Forward">Doorsturen</string> <string name="Forward">Doorsturen</string>
<string name="Retry">Opnieuw proberen</string> <string name="Retry">Opnieuw proberen</string>
<string name="FromCamera">Van camera</string> <string name="FromCamera">Van camera</string>
@ -734,6 +769,7 @@
<string name="UserAlreadyInGroup">Gebruiker neemt al deel aan de groep</string> <string name="UserAlreadyInGroup">Gebruiker neemt al deel aan de groep</string>
<string name="ForwardMessagesTo">Berichten doorsturen naar %1$s?</string> <string name="ForwardMessagesTo">Berichten doorsturen naar %1$s?</string>
<string name="SendMessagesTo">Berichten naar %1$s versturen?</string> <string name="SendMessagesTo">Berichten naar %1$s versturen?</string>
<string name="SendContactTo">Contact delen met %1$s?</string>
<string name="AreYouSureLogout">Weet je zeker dat je wilt uitloggen?\n\nTelegram kun je naadloos op al je apparaten tegelijkertijd gebruiken.\n\nLet op! Als je uitlogt worden al je geheime chats verwijderd.</string> <string name="AreYouSureLogout">Weet je zeker dat je wilt uitloggen?\n\nTelegram kun je naadloos op al je apparaten tegelijkertijd gebruiken.\n\nLet op! Als je uitlogt worden al je geheime chats verwijderd.</string>
<string name="AreYouSureSessions">Alle apparaten behalve het huidige apparaat uitloggen?</string> <string name="AreYouSureSessions">Alle apparaten behalve het huidige apparaat uitloggen?</string>
<string name="AreYouSureDeleteAndExit">Verwijderen en de groep verlaten?</string> <string name="AreYouSureDeleteAndExit">Verwijderen en de groep verlaten?</string>
@ -747,6 +783,7 @@
<string name="AreYouSureClearHistory">Geschiedenis echt wissen? </string> <string name="AreYouSureClearHistory">Geschiedenis echt wissen? </string>
<string name="AreYouSureDeleteMessages">%1$s echt verwijderen?</string> <string name="AreYouSureDeleteMessages">%1$s echt verwijderen?</string>
<string name="SendMessagesToGroup">Berichten naar %1$s versturen?</string> <string name="SendMessagesToGroup">Berichten naar %1$s versturen?</string>
<string name="SendContactToGroup">Contact delen met %1$s?</string>
<string name="ForwardMessagesToGroup">Berichten doorsturen naar %1$s?</string> <string name="ForwardMessagesToGroup">Berichten doorsturen naar %1$s?</string>
<string name="FeatureUnavailable">Sorry, deze functie is momenteel niet beschikbaar in jouw land.</string> <string name="FeatureUnavailable">Sorry, deze functie is momenteel niet beschikbaar in jouw land.</string>
<string name="NoUsernameFound">Er is geen Telegram-account met deze gebruikersnaam.</string> <string name="NoUsernameFound">Er is geen Telegram-account met deze gebruikersnaam.</string>
@ -894,12 +931,12 @@
<string name="Photos_few">%1$d foto\'s</string> <string name="Photos_few">%1$d foto\'s</string>
<string name="Photos_many">%1$d foto\'s</string> <string name="Photos_many">%1$d foto\'s</string>
<string name="Photos_other">%1$d foto\'s</string> <string name="Photos_other">%1$d foto\'s</string>
<string name="LastSeenMinutes_zero">laatst gezien %1$d minuten geleden</string> <string name="LastSeenMinutes_zero">laatst gezien %1$d min geleden</string>
<string name="LastSeenMinutes_one">laatst gezien %1$d minuut geleden</string> <string name="LastSeenMinutes_one">laatst gezien %1$d minuut geleden</string>
<string name="LastSeenMinutes_two">laatst gezien %1$d minuten geleden</string> <string name="LastSeenMinutes_two">laatst gezien %1$d min geleden</string>
<string name="LastSeenMinutes_few">laatst gezien %1$d minuten geleden</string> <string name="LastSeenMinutes_few">laatst gezien %1$d min geleden</string>
<string name="LastSeenMinutes_many">laatst gezien %1$d minuten geleden</string> <string name="LastSeenMinutes_many">laatst gezien %1$d min geleden</string>
<string name="LastSeenMinutes_other">laatst gezien %1$d minuten geleden</string> <string name="LastSeenMinutes_other">laatst gezien %1$d min geleden</string>
<string name="LastSeenHours_zero">laatst gezien %1$d uur geleden</string> <string name="LastSeenHours_zero">laatst gezien %1$d uur geleden</string>
<string name="LastSeenHours_one">laatst gezien %1$d uur geleden</string> <string name="LastSeenHours_one">laatst gezien %1$d uur geleden</string>
<string name="LastSeenHours_two">laatst gezien %1$d uur geleden</string> <string name="LastSeenHours_two">laatst gezien %1$d uur geleden</string>
@ -973,8 +1010,8 @@
<string name="formatterDay12H">h:mm a</string> <string name="formatterDay12H">h:mm a</string>
<string name="formatDateAtTime">%1$s om %2$s</string> <string name="formatDateAtTime">%1$s om %2$s</string>
<!--update text--> <!--update text-->
<string name="updateText">Plus Messenger voor Android is bijgewerkt. Nieuw in versie 3.2.6:\n\n- Nieuwe animaties en andere visuele verbeteringen\n- Ondersteuning voor nieuwe Emoji\n-Tijdsaanduiding voor laatst gezien gelijk aan iOS\n-Probleemoplossing en andere verbeteringen</string> <string name="updateText">Plus Messenger voor Android is bijgewerkt. Nieuw in versie 3.3.1:\n\n- Meerdere beheerders in groepen, naast het wijzigen van de groepsnaam en afbeelding kunnen beheerders ook leden toevoegen en verwijderen.\n- Groepen die de limiet van 200 deelnemers hebben bereikt kunnen worden geüpgraded naar supergroepen met maximaal 1000 deelnemers.\n- Snel delen in kanalen via de knop rechts van de berichten.\n\nMeer informatie over deze update is hier te vinden:\nhttps://telegram.org/blog/supergroups</string>
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--><!-- <!--Telegram+--><!--
<string name="updatePlusText"></string>--> <string name="updatePlusText"></string>-->
<string name="TelegramForAndroid">Plus Messenger voor Android</string> <string name="TelegramForAndroid">Plus Messenger voor Android</string>

View File

@ -1,6 +1,10 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version="1.0" encoding="utf-8"?>
<!--https://www.transifex.com/projects/p/telegram/language/pt_BR/members/-->
<resources> <resources>
<string name="AppName">Plus Messenger</string> <string name="AppName">Plus Messenger</string>
<string name="AppNameBeta">Telegram Beta</string>
<string name="LanguageName">Português (Brasil)</string> <string name="LanguageName">Português (Brasil)</string>
<string name="LanguageNameInEnglish">Português (Brasil)</string> <string name="LanguageNameInEnglish">Português (Brasil)</string>
<string name="LanguageCode">pt_BR</string> <string name="LanguageCode">pt_BR</string>
@ -57,12 +61,33 @@
<string name="MuteDisable">Desativar</string> <string name="MuteDisable">Desativar</string>
<string name="Hashtags">HASHTAGS</string> <string name="Hashtags">HASHTAGS</string>
<string name="Recent">RECENTE</string> <string name="Recent">RECENTE</string>
<string name="LinkPreview">Prévia do link</string>
<!--channels--> <!--channels-->
<string name="SetAsAdmin">Promover a administrador</string>
<string name="DescriptionInfoMega">Você pode fornecer uma descrição opcional para seu grupo.</string>
<string name="LeaveMega">Sair do Grupo</string>
<string name="DeleteMega">Apagar Grupo</string>
<string name="LeaveMegaMenu">Sair do Grupo</string>
<string name="DeleteMegaMenu">Apagar Grupo</string>
<string name="MegaDeleteInfo">Você perderá todas as mensagens neste grupo.</string>
<string name="MegaAdminsInfo">Você pode adicionar administradores para ajudar você a gerenciar seu grupo. Toque e segure para removê-los.</string>
<string name="MegaDeleteAlert">Espere! Apagar este grupo removerá todos os membros e todas as mensagens serão perdidas. Apagar o grupo mesmo assim?</string>
<string name="ActionCreateMega">Grupo criado</string>
<string name="MegaAddedBy">un1 adicionou você ao grupo</string>
<string name="MegaLeaveAlert">Você tem certeza que deseja sair do grupo?</string>
<string name="GroupUserCantAdd">Desculpe, você não pode adicionar este usuário a grupos.</string>
<string name="GroupUserAddLimit">Desculpe, este grupo está cheio.</string>
<string name="GroupUserLeftError">Desculpe, este usuário decidiu sair deste grupo, de maneira que você não pode convidá-lo de volta.</string>
<string name="GroupUserCantAdmin">Desculpe, há administradores demais neste grupo.</string>
<string name="GroupUserCantBot">Desculpe, há bots demais neste grupo.</string>
<string name="ActionMigrateFromGroup">Este grupo foi atualizado para um supergrupo</string>
<string name="ActionMigrateFromGroupNotify">%1$s foi atualizado para um supergrupo</string>
<string name="NoBlockedGroup">Usuários bloqueados são removidos do grupo e só podem voltar se convidados por um administrador. Convites por link não funcionam para eles.</string>
<string name="NewChannel">Novo Canal</string> <string name="NewChannel">Novo Canal</string>
<string name="EnterChannelName">Nome do canal</string> <string name="EnterChannelName">Nome do canal</string>
<string name="Comments">Comentários</string> <string name="Comments">Comentários</string>
<string name="CommentsInfo">Se você habilitar comentários, pessoas poderão discutir seu post no canal.</string> <string name="CommentsInfo">Se você habilitar comentários, pessoas poderão discutir seu post no canal.</string>
<string name="AddMutual">Adicionar contatos para o seu canal</string> <string name="AddMutual">Adicionar contatos no canal</string>
<string name="ChannelUsernameHelp">Pessoas podem compartilhar esse link com outros e encontrar seu canal usando a busca do Telegram.</string> <string name="ChannelUsernameHelp">Pessoas podem compartilhar esse link com outros e encontrar seu canal usando a busca do Telegram.</string>
<string name="ChannelUsernamePlaceholder">link</string> <string name="ChannelUsernamePlaceholder">link</string>
<string name="ChannelPrivateLinkHelp">Pessoas podem entrar em seu canal com este link. Você pode desativar o link quando quiser.</string> <string name="ChannelPrivateLinkHelp">Pessoas podem entrar em seu canal com este link. Você pode desativar o link quando quiser.</string>
@ -80,7 +105,7 @@
<string name="ChannelSettings">Configurações</string> <string name="ChannelSettings">Configurações</string>
<string name="ChannelJoin">ENTRAR</string> <string name="ChannelJoin">ENTRAR</string>
<string name="OpenChannelProfile">Info do Canal</string> <string name="OpenChannelProfile">Info do Canal</string>
<string name="ChannelBroadcast">Tramissão</string> <string name="ChannelBroadcast">Transmissão</string>
<string name="ChannelComment">Comentário</string> <string name="ChannelComment">Comentário</string>
<string name="ShowDiscussion">mostrar comentários</string> <string name="ShowDiscussion">mostrar comentários</string>
<string name="ChannelAlertTitle">O que é um Canal?</string> <string name="ChannelAlertTitle">O que é um Canal?</string>
@ -108,7 +133,6 @@
<string name="ActionChannelChangedPhoto">Foto do canal alterada</string> <string name="ActionChannelChangedPhoto">Foto do canal alterada</string>
<string name="ActionChannelRemovedPhoto">Foto do canal removida</string> <string name="ActionChannelRemovedPhoto">Foto do canal removida</string>
<string name="ActionChannelChangedTitle">Nome do canal alterado para un2</string> <string name="ActionChannelChangedTitle">Nome do canal alterado para un2</string>
<string name="ActionChannelInvite">un1 adicionado ao canal un2</string>
<string name="ChannelPublicLimitReached">Desculpe, você criou muitos canais públicos. Você pode criar um canal privado ou apagar um de seus canais existentes primeiro.</string> <string name="ChannelPublicLimitReached">Desculpe, você criou muitos canais públicos. Você pode criar um canal privado ou apagar um de seus canais existentes primeiro.</string>
<string name="ChannelModerator">Moderador</string> <string name="ChannelModerator">Moderador</string>
<string name="ChannelCreator">Criador</string> <string name="ChannelCreator">Criador</string>
@ -124,12 +148,12 @@
<string name="ChannelLinkInfo">Qualquer um com Telegram instalado poderá entrar no seu canal abrindo este link.</string> <string name="ChannelLinkInfo">Qualquer um com Telegram instalado poderá entrar no seu canal abrindo este link.</string>
<string name="ChannelAdminsInfo">Você pode adicionar administradores para ajudar você a gerenciar seu canal. Aperte e segure para removê-los.</string> <string name="ChannelAdminsInfo">Você pode adicionar administradores para ajudar você a gerenciar seu canal. Aperte e segure para removê-los.</string>
<string name="ChannelJoinTo">Você deseja entrar no canal \'%1$s\'?</string> <string name="ChannelJoinTo">Você deseja entrar no canal \'%1$s\'?</string>
<string name="ChannelCantOpenPrivate">Desculpe, esse canal não é acessível.</string> <string name="ChannelCantOpenPrivate">Desculpe, esta conversa não pode mais ser acessada.</string>
<string name="ChannelAddToTitle">Adicionar %1$s ao grupo %2$s?</string>
<string name="ChannelAddTo">Adicionar %1$s ao canal?</string> <string name="ChannelAddTo">Adicionar %1$s ao canal?</string>
<string name="ChannelUserLeftError">Desculpe, esse usuário decidiu sair do grupo, você não pode adicioná-lo novamente.</string> <string name="ChannelUserLeftError">Desculpe, este usuário decidiu sair deste canal, então você não pode convidá-lo de volta.</string>
<string name="ChannelUserCantAdd">Desculpe, você não pode adicionar esse usuário em canais.</string> <string name="ChannelUserCantAdd">Desculpe, você não pode adicionar esse usuário em canais.</string>
<string name="ChannelUserCantAdmin">Desculpe, muitos administradores nesse canal.</string> <string name="ChannelUserCantAdmin">Desculpe, muitos administradores nesse canal.</string>
<string name="ChannelUserCantBot">Desculpe, há bots demais neste canal.</string>
<string name="ChannelUserAddLimit">Desculpe, você só pode adicionar os primeiros 200 membros ao canal. Note que um número ilimitado de pessoas podem entrar via link do canal.</string> <string name="ChannelUserAddLimit">Desculpe, você só pode adicionar os primeiros 200 membros ao canal. Note que um número ilimitado de pessoas podem entrar via link do canal.</string>
<string name="ChannelAddedBy">un1 adicionou você ao canal</string> <string name="ChannelAddedBy">un1 adicionou você ao canal</string>
<string name="ChannelJoined">Você entrou no canal</string> <string name="ChannelJoined">Você entrou no canal</string>
@ -239,6 +263,7 @@
<string name="NobodyLikesSpam2">Desculpe, você só pode adicionar contatos mútuos à grupos no momento.</string> <string name="NobodyLikesSpam2">Desculpe, você só pode adicionar contatos mútuos à grupos no momento.</string>
<string name="NobodyLikesSpamUrl">https://telegram.org/faq/br#no-consigo-enviar-mensagens-para-no-contatos</string> <string name="NobodyLikesSpamUrl">https://telegram.org/faq/br#no-consigo-enviar-mensagens-para-no-contatos</string>
<string name="MoreInfo">Mais informações</string> <string name="MoreInfo">Mais informações</string>
<string name="ShareSendTo">Enviar para...</string>
<!--notification--> <!--notification-->
<string name="MessageLifetimeChanged">%1$s estabeleceu o tempo de autodestruição para %2$s </string> <string name="MessageLifetimeChanged">%1$s estabeleceu o tempo de autodestruição para %2$s </string>
<string name="MessageLifetimeChangedOutgoing">Você estabeleceu o tempo de autodestruição para %1$s</string> <string name="MessageLifetimeChangedOutgoing">Você estabeleceu o tempo de autodestruição para %1$s</string>
@ -272,7 +297,7 @@
<string name="NotificationGroupKickYou">%1$s removeu você do grupo %2$s</string> <string name="NotificationGroupKickYou">%1$s removeu você do grupo %2$s</string>
<string name="NotificationGroupLeftMember">%1$s saiu do grupo %2$s</string> <string name="NotificationGroupLeftMember">%1$s saiu do grupo %2$s</string>
<string name="NotificationContactJoined">%1$s entrou para o Telegram!</string> <string name="NotificationContactJoined">%1$s entrou para o Telegram!</string>
<string name="NotificationUnrecognizedDevice">%1$s,\nNós detectamos que alguém acessou a sua conta a partir de um novo aparelho em %2$s\n\nAparelho: %3$s\nLocalização: %4$s\n\nSe não foi você, você pode ir em Configurações - Provacidade e Segurança - Sessões, e terminar aquela sessão.\n\nSe você acha que alguém acessou a sua conta contra a sua vontade, você pode habilitar a verificação em duas etapas nas configurações de Privacidade e Segurança.\n\nAtenciosamente,\nEquipe Telegram</string> <string name="NotificationUnrecognizedDevice">%1$s,\nNós detectamos que alguém acessou a sua conta a partir de um novo aparelho em %2$s\n\nAparelho: %3$s\nLocalização: %4$s\n\nSe não foi você, você pode ir em Configurações - Privacidade e Segurança - Sessões, e terminar aquela sessão.\n\nSe você acha que alguém acessou a sua conta contra a sua vontade, você pode habilitar a verificação em duas etapas nas configurações de Privacidade e Segurança.\n\nAtenciosamente,\nEquipe Telegram</string>
<string name="NotificationContactNewPhoto">%1$s atualizou a foto do perfil</string> <string name="NotificationContactNewPhoto">%1$s atualizou a foto do perfil</string>
<string name="NotificationInvitedToGroupByLink">%1$s entrou para o grupo %2$s via link de convite</string> <string name="NotificationInvitedToGroupByLink">%1$s entrou para o grupo %2$s via link de convite</string>
<string name="Reply">Responder</string> <string name="Reply">Responder</string>
@ -314,13 +339,22 @@
<string name="CopyLink">Copiar Link</string> <string name="CopyLink">Copiar Link</string>
<string name="ShareLink">Compartilhar Link</string> <string name="ShareLink">Compartilhar Link</string>
<string name="LinkInfo">Qualquer um com Telegram instalado poderá entrar no seu grupo abrindo este link.</string> <string name="LinkInfo">Qualquer um com Telegram instalado poderá entrar no seu grupo abrindo este link.</string>
<!--set admins view-->
<string name="SetAdminsTitle">Administradores de Conversas</string>
<string name="SetAdminsAll">Todos os membros são Administradores</string>
<string name="SetAdminsAllInfo">Todos os membros podem adicionar novos membros, editar o nome e a foto do grupo.</string>
<string name="SetAdminsNotAllInfo">Somente administradores podem adicionar e remover membros, editar nome foto do grupo.</string>
<!--group info view--> <!--group info view-->
<string name="SharedMedia">Mídia compartilhada</string> <string name="SharedMedia">Mídia compartilhada</string>
<string name="SETTINGS">Configurações</string> <string name="SETTINGS">Configurações</string>
<string name="AddMember">Adicionar membro</string> <string name="AddMember">Adicionar membro</string>
<string name="SetAdmins">Definir administradores</string>
<string name="DeleteAndExit">Apagar e sair do grupo</string> <string name="DeleteAndExit">Apagar e sair do grupo</string>
<string name="Notifications">Notificações</string> <string name="Notifications">Notificações</string>
<string name="KickFromGroup">Remover do grupo</string> <string name="KickFromGroup">Remover do grupo</string>
<string name="ConvertGroup">Atualizar para Supergrupo</string>
<string name="ConvertGroupAlert">Por favor note que os membros do grupo precisarão atualizar o aplicativo do Telegram até a última versão para verem seu supergrupo. Você tem certeza que deseja atualizar este grupo?</string>
<string name="ConvertGroupInfo"><![CDATA[<b>]]>Limite de membros atingido.<![CDATA[</b>]]>\n\nPara ir além do limite e ter funções adcionais, atualize para um supergrupo:\n\n• Supergrupos podem ter até %1$s\n• Novos membros veêm todo o histórico de conversas\n• Administradores deletam mensagens para todos\n• Notificações são silenciadas por padrão</string>
<!--contact info view--> <!--contact info view-->
<string name="ShareContact">Compartilhar</string> <string name="ShareContact">Compartilhar</string>
<string name="AddContact">Adicionar</string> <string name="AddContact">Adicionar</string>
@ -654,8 +688,8 @@
<string name="BotInvite">Adicionar Ao Grupo</string> <string name="BotInvite">Adicionar Ao Grupo</string>
<string name="BotSettings">Configurações</string> <string name="BotSettings">Configurações</string>
<string name="BotHelp">Ajuda</string> <string name="BotHelp">Ajuda</string>
<string name="BotStatusRead">tem acesso as mensagens</string> <string name="BotStatusRead">tem acesso às mensagens</string>
<string name="BotStatusCantRead">não tem acesso as mensagens</string> <string name="BotStatusCantRead">não tem acesso às mensagens</string>
<string name="BotInfoTitle">O que esse bot pode fazer?</string> <string name="BotInfoTitle">O que esse bot pode fazer?</string>
<string name="BotStart">COMEÇAR</string> <string name="BotStart">COMEÇAR</string>
<string name="BotUnblock">REINICIAR</string> <string name="BotUnblock">REINICIAR</string>
@ -674,6 +708,7 @@
<string name="Call">Ligar</string> <string name="Call">Ligar</string>
<string name="Copy">Copiar</string> <string name="Copy">Copiar</string>
<string name="Delete">Apagar</string> <string name="Delete">Apagar</string>
<string name="DeleteAndStop">Apagar e parar</string>
<string name="Forward">Encaminhar</string> <string name="Forward">Encaminhar</string>
<string name="Retry">Tentar novamente</string> <string name="Retry">Tentar novamente</string>
<string name="FromCamera">Câmera</string> <string name="FromCamera">Câmera</string>
@ -709,7 +744,7 @@
<string name="AttachLocation">Localização</string> <string name="AttachLocation">Localização</string>
<string name="AttachContact">Contato</string> <string name="AttachContact">Contato</string>
<string name="AttachDocument">Arquivo</string> <string name="AttachDocument">Arquivo</string>
<string name="AttachSticker">Adesivo</string> <string name="AttachSticker">Sticker</string>
<string name="AttachAudio">Áudio</string> <string name="AttachAudio">Áudio</string>
<string name="FromYou">Você</string> <string name="FromYou">Você</string>
<string name="ActionTakeScreenshootYou">Você realizou uma captura da tela!</string> <string name="ActionTakeScreenshootYou">Você realizou uma captura da tela!</string>
@ -728,12 +763,13 @@
<string name="NoHandleAppInstalled">Você não possui um aplicativo que suporte o tipo de arquivo \'%1$s\', por favor instale um para continuar</string> <string name="NoHandleAppInstalled">Você não possui um aplicativo que suporte o tipo de arquivo \'%1$s\', por favor instale um para continuar</string>
<string name="InviteUser">Este usuário ainda não possui Telegram, deseja enviar um convite?</string> <string name="InviteUser">Este usuário ainda não possui Telegram, deseja enviar um convite?</string>
<string name="AreYouSure">Você tem certeza?</string> <string name="AreYouSure">Você tem certeza?</string>
<string name="AddToTheGroupTitle">Adicionar %1$s ao grupo %2$s?</string> <string name="AddToTheGroupTitle">Adcione %1$s ao chat %2$s?</string>
<string name="AddToTheGroupForwardCount">Número de mensagens antigas para encaminhar:</string> <string name="AddToTheGroupForwardCount">Número de mensagens antigas para encaminhar:</string>
<string name="AddToTheGroup">Adicionar %1$s no grupo?</string> <string name="AddToTheGroup">Adicionar %1$s no grupo?</string>
<string name="UserAlreadyInGroup">Este usuário já está neste grupo</string> <string name="UserAlreadyInGroup">Este usuário já está neste grupo</string>
<string name="ForwardMessagesTo">Encaminhar mensagem para %1$s?</string> <string name="ForwardMessagesTo">Encaminhar mensagem para %1$s?</string>
<string name="SendMessagesTo">Enviar mensagens para %1$s?</string> <string name="SendMessagesTo">Enviar mensagens para %1$s?</string>
<string name="SendContactTo">Enviar contato para %1$s?</string>
<string name="AreYouSureLogout">Você tem certeza que desejar sair?\n\nSaiba que você pode usar o Telegram em vários dispositivos de uma vez.\n\nLembre-se, sair apaga todos os seus Chats Secretos.</string> <string name="AreYouSureLogout">Você tem certeza que desejar sair?\n\nSaiba que você pode usar o Telegram em vários dispositivos de uma vez.\n\nLembre-se, sair apaga todos os seus Chats Secretos.</string>
<string name="AreYouSureSessions">Você tem certeza que deseja terminar todas as outras sessões?</string> <string name="AreYouSureSessions">Você tem certeza que deseja terminar todas as outras sessões?</string>
<string name="AreYouSureDeleteAndExit">Você tem certeza que apagar e sair do grupo?</string> <string name="AreYouSureDeleteAndExit">Você tem certeza que apagar e sair do grupo?</string>
@ -747,6 +783,7 @@
<string name="AreYouSureClearHistory">Você tem certeza que deseja limpar o histórico?</string> <string name="AreYouSureClearHistory">Você tem certeza que deseja limpar o histórico?</string>
<string name="AreYouSureDeleteMessages">Você tem certeza que deseja apagar %1$s?</string> <string name="AreYouSureDeleteMessages">Você tem certeza que deseja apagar %1$s?</string>
<string name="SendMessagesToGroup">Enviar mensagens para %1$s?</string> <string name="SendMessagesToGroup">Enviar mensagens para %1$s?</string>
<string name="SendContactToGroup">Enviar contato para %1$s?</string>
<string name="ForwardMessagesToGroup">Encaminhar mensagem para %1$s?</string> <string name="ForwardMessagesToGroup">Encaminhar mensagem para %1$s?</string>
<string name="FeatureUnavailable">Desculpe, esta funcionalidade não está disponível para seu país.</string> <string name="FeatureUnavailable">Desculpe, esta funcionalidade não está disponível para seu país.</string>
<string name="NoUsernameFound">Não há conta do Telegram com esse nome de usuário</string> <string name="NoUsernameFound">Não há conta do Telegram com esse nome de usuário</string>
@ -973,10 +1010,10 @@
<string name="formatterDay12H">h:mm a</string> <string name="formatterDay12H">h:mm a</string>
<string name="formatDateAtTime">%1$s às %2$s</string> <string name="formatDateAtTime">%1$s às %2$s</string>
<!--update text--> <!--update text-->
<string name="updateText">Plus Messenger para Android foi atualizado. Novidades na versão 3.2.6:\n\n- Novas animações e melhorias no visual\n- Suporte para novos emojis\n- Outras melhorias e resoluções de bugs</string> <string name="updateText">Plus Messenger para Android foi atualizado. Novidades na versão 3.3.1:\n\n- Os grupos agora podem ter múltiplos administradores com permissão para editar o nome e a imagem do grupo, adicionar e remover membros.\n- Os grupos que alcançarem 200 usuários podem ser transformados em supergrupos, que permitem até 1000 membros.\n- Os canais contam com um botão de compartilhamento rápido ao lado das mensagens.\n\nVocê pode ver mais sobre os supergrupos e sobre os demais assuntos no nosso blog:\nhttps://telegram.org/blog/supergroups</string>
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--> <!--Telegram+--><!--
<string name="updatePlusText">\n\nNovidades na versão 3.2.6.2:\n\n- Agora o cabeçalho adquire cor do tema na lista de Apps Recentes do Android\n- Tamanho da Lista de Menção aumentado na tela de chat\n- Agora canais também podem ser silenciados diretamente pela tela principal\n- Adicionada mod para definir raio do avatar no cabeçalho da tela de chat\n- Adicionada mod mod para definir cor do texto de digitação no cabeçalho da tela de chat\n- Correções de erros</string> <string name="updatePlusText">\n\nNovidades na versão 3.3.1.0:\n\n- Correções de erros</string>-->
<string name="TelegramForAndroid">Plus Messenger para Android</string> <string name="TelegramForAndroid">Plus Messenger para Android</string>
<string name="Theming">Personalização</string> <string name="Theming">Personalização</string>
<string name="colorHexInvalid">Código de cor HEX inválido!</string> <string name="colorHexInvalid">Código de cor HEX inválido!</string>

View File

@ -4,6 +4,7 @@
<resources> <resources>
<string name="AppName">Plus Messenger</string> <string name="AppName">Plus Messenger</string>
<string name="AppNameBeta">Telegram Beta</string>
<string name="LanguageName">Português (Portugal)</string> <string name="LanguageName">Português (Portugal)</string>
<string name="LanguageNameInEnglish">Portuguese (Portugal)</string> <string name="LanguageNameInEnglish">Portuguese (Portugal)</string>
<string name="LanguageCode">pt_PT</string> <string name="LanguageCode">pt_PT</string>
@ -60,12 +61,33 @@
<string name="MuteDisable">Desativar</string> <string name="MuteDisable">Desativar</string>
<string name="Hashtags">HASHTAGS</string> <string name="Hashtags">HASHTAGS</string>
<string name="Recent">RECENTE</string> <string name="Recent">RECENTE</string>
<string name="LinkPreview">Prévia do link</string>
<!--channels--> <!--channels-->
<string name="SetAsAdmin">Promover a administrador</string>
<string name="DescriptionInfoMega">Você pode fornecer uma descrição opcional para seu grupo.</string>
<string name="LeaveMega">Sair do Grupo</string>
<string name="DeleteMega">Apagar Grupo</string>
<string name="LeaveMegaMenu">Sair do Grupo</string>
<string name="DeleteMegaMenu">Apagar Grupo</string>
<string name="MegaDeleteInfo">Você perderá todas as mensagens neste grupo.</string>
<string name="MegaAdminsInfo">Você pode adicionar administradores para ajudar você a gerenciar seu grupo. Toque e segure para removê-los.</string>
<string name="MegaDeleteAlert">Espere! Apagar este grupo removerá todos os membros e todas as mensagens serão perdidas. Apagar o grupo mesmo assim?</string>
<string name="ActionCreateMega">Grupo criado</string>
<string name="MegaAddedBy">un1 adicionou você ao grupo</string>
<string name="MegaLeaveAlert">Você tem certeza que deseja sair do grupo?</string>
<string name="GroupUserCantAdd">Desculpe, você não pode adicionar este usuário a grupos.</string>
<string name="GroupUserAddLimit">Desculpe, este grupo está cheio.</string>
<string name="GroupUserLeftError">Desculpe, este usuário decidiu sair deste grupo, de maneira que você não pode convidá-lo de volta.</string>
<string name="GroupUserCantAdmin">Desculpe, há administradores demais neste grupo.</string>
<string name="GroupUserCantBot">Desculpe, há bots demais neste grupo.</string>
<string name="ActionMigrateFromGroup">Este grupo foi atualizado para um supergrupo</string>
<string name="ActionMigrateFromGroupNotify">%1$s foi atualizado para um supergrupo</string>
<string name="NoBlockedGroup">Usuários bloqueados são removidos do grupo e só podem voltar se convidados por um administrador. Convites por link não funcionam para eles.</string>
<string name="NewChannel">Novo Canal</string> <string name="NewChannel">Novo Canal</string>
<string name="EnterChannelName">Nome do canal</string> <string name="EnterChannelName">Nome do canal</string>
<string name="Comments">Comentários</string> <string name="Comments">Comentários</string>
<string name="CommentsInfo">Se você habilitar comentários, pessoas poderão discutir seu post no canal.</string> <string name="CommentsInfo">Se você habilitar comentários, pessoas poderão discutir seu post no canal.</string>
<string name="AddMutual">Adicionar contatos para o seu canal</string> <string name="AddMutual">Adicionar contatos no canal</string>
<string name="ChannelUsernameHelp">Pessoas podem compartilhar esse link com outros e encontrar seu canal usando a busca do Telegram.</string> <string name="ChannelUsernameHelp">Pessoas podem compartilhar esse link com outros e encontrar seu canal usando a busca do Telegram.</string>
<string name="ChannelUsernamePlaceholder">link</string> <string name="ChannelUsernamePlaceholder">link</string>
<string name="ChannelPrivateLinkHelp">Pessoas podem entrar em seu canal com este link. Você pode desativar o link quando quiser.</string> <string name="ChannelPrivateLinkHelp">Pessoas podem entrar em seu canal com este link. Você pode desativar o link quando quiser.</string>
@ -83,7 +105,7 @@
<string name="ChannelSettings">Configurações</string> <string name="ChannelSettings">Configurações</string>
<string name="ChannelJoin">ENTRAR</string> <string name="ChannelJoin">ENTRAR</string>
<string name="OpenChannelProfile">Info do Canal</string> <string name="OpenChannelProfile">Info do Canal</string>
<string name="ChannelBroadcast">Tramissão</string> <string name="ChannelBroadcast">Transmissão</string>
<string name="ChannelComment">Comentário</string> <string name="ChannelComment">Comentário</string>
<string name="ShowDiscussion">mostrar comentários</string> <string name="ShowDiscussion">mostrar comentários</string>
<string name="ChannelAlertTitle">O que é um Canal?</string> <string name="ChannelAlertTitle">O que é um Canal?</string>
@ -111,7 +133,6 @@
<string name="ActionChannelChangedPhoto">Foto do canal alterada</string> <string name="ActionChannelChangedPhoto">Foto do canal alterada</string>
<string name="ActionChannelRemovedPhoto">Foto do canal removida</string> <string name="ActionChannelRemovedPhoto">Foto do canal removida</string>
<string name="ActionChannelChangedTitle">Nome do canal alterado para un2</string> <string name="ActionChannelChangedTitle">Nome do canal alterado para un2</string>
<string name="ActionChannelInvite">un1 adicionado ao canal un2</string>
<string name="ChannelPublicLimitReached">Desculpe, você criou muitos canais públicos. Você pode criar um canal privado ou apagar um de seus canais existentes primeiro.</string> <string name="ChannelPublicLimitReached">Desculpe, você criou muitos canais públicos. Você pode criar um canal privado ou apagar um de seus canais existentes primeiro.</string>
<string name="ChannelModerator">Moderador</string> <string name="ChannelModerator">Moderador</string>
<string name="ChannelCreator">Criador</string> <string name="ChannelCreator">Criador</string>
@ -127,12 +148,12 @@
<string name="ChannelLinkInfo">Qualquer um com Telegram instalado poderá entrar no seu canal abrindo este link.</string> <string name="ChannelLinkInfo">Qualquer um com Telegram instalado poderá entrar no seu canal abrindo este link.</string>
<string name="ChannelAdminsInfo">Você pode adicionar administradores para ajudar você a gerenciar seu canal. Aperte e segure para removê-los.</string> <string name="ChannelAdminsInfo">Você pode adicionar administradores para ajudar você a gerenciar seu canal. Aperte e segure para removê-los.</string>
<string name="ChannelJoinTo">Você deseja entrar no canal \'%1$s\'?</string> <string name="ChannelJoinTo">Você deseja entrar no canal \'%1$s\'?</string>
<string name="ChannelCantOpenPrivate">Desculpe, esse canal não é acessível.</string> <string name="ChannelCantOpenPrivate">Desculpe, esta conversa não pode mais ser acessada.</string>
<string name="ChannelAddToTitle">Adicionar %1$s ao grupo %2$s?</string>
<string name="ChannelAddTo">Adicionar %1$s ao canal?</string> <string name="ChannelAddTo">Adicionar %1$s ao canal?</string>
<string name="ChannelUserLeftError">Desculpe, esse usuário decidiu sair do grupo, você não pode adicioná-lo novamente.</string> <string name="ChannelUserLeftError">Desculpe, este usuário decidiu sair deste canal, então você não pode convidá-lo de volta.</string>
<string name="ChannelUserCantAdd">Desculpe, você não pode adicionar esse usuário em canais.</string> <string name="ChannelUserCantAdd">Desculpe, você não pode adicionar esse usuário em canais.</string>
<string name="ChannelUserCantAdmin">Desculpe, muitos administradores nesse canal.</string> <string name="ChannelUserCantAdmin">Desculpe, muitos administradores nesse canal.</string>
<string name="ChannelUserCantBot">Desculpe, há bots demais neste canal.</string>
<string name="ChannelUserAddLimit">Desculpe, você só pode adicionar os primeiros 200 membros ao canal. Note que um número ilimitado de pessoas podem entrar via link do canal.</string> <string name="ChannelUserAddLimit">Desculpe, você só pode adicionar os primeiros 200 membros ao canal. Note que um número ilimitado de pessoas podem entrar via link do canal.</string>
<string name="ChannelAddedBy">un1 adicionou você ao canal</string> <string name="ChannelAddedBy">un1 adicionou você ao canal</string>
<string name="ChannelJoined">Você entrou no canal</string> <string name="ChannelJoined">Você entrou no canal</string>
@ -242,6 +263,7 @@
<string name="NobodyLikesSpam2">Desculpe, você só pode adicionar contatos mútuos à grupos no momento.</string> <string name="NobodyLikesSpam2">Desculpe, você só pode adicionar contatos mútuos à grupos no momento.</string>
<string name="NobodyLikesSpamUrl">https://telegram.org/faq/br#no-consigo-enviar-mensagens-para-no-contatos</string> <string name="NobodyLikesSpamUrl">https://telegram.org/faq/br#no-consigo-enviar-mensagens-para-no-contatos</string>
<string name="MoreInfo">Mais informações</string> <string name="MoreInfo">Mais informações</string>
<string name="ShareSendTo">Enviar para...</string>
<!--notification--> <!--notification-->
<string name="MessageLifetimeChanged">%1$s estabeleceu o tempo de autodestruição para %2$s </string> <string name="MessageLifetimeChanged">%1$s estabeleceu o tempo de autodestruição para %2$s </string>
<string name="MessageLifetimeChangedOutgoing">Você estabeleceu o tempo de autodestruição para %1$s</string> <string name="MessageLifetimeChangedOutgoing">Você estabeleceu o tempo de autodestruição para %1$s</string>
@ -275,7 +297,7 @@
<string name="NotificationGroupKickYou">%1$s removeu você do grupo %2$s</string> <string name="NotificationGroupKickYou">%1$s removeu você do grupo %2$s</string>
<string name="NotificationGroupLeftMember">%1$s saiu do grupo %2$s</string> <string name="NotificationGroupLeftMember">%1$s saiu do grupo %2$s</string>
<string name="NotificationContactJoined">%1$s entrou para o Telegram!</string> <string name="NotificationContactJoined">%1$s entrou para o Telegram!</string>
<string name="NotificationUnrecognizedDevice">%1$s,\nNós detectamos que alguém acessou a sua conta a partir de um novo aparelho em %2$s\n\nAparelho: %3$s\nLocalização: %4$s\n\nSe não foi você, você pode ir em Configurações - Provacidade e Segurança - Sessões, e terminar aquela sessão.\n\nSe você acha que alguém acessou a sua conta contra a sua vontade, você pode habilitar a verificação em duas etapas nas configurações de Privacidade e Segurança.\n\nAtenciosamente,\nEquipe Telegram</string> <string name="NotificationUnrecognizedDevice">%1$s,\nNós detectamos que alguém acessou a sua conta a partir de um novo aparelho em %2$s\n\nAparelho: %3$s\nLocalização: %4$s\n\nSe não foi você, você pode ir em Configurações - Privacidade e Segurança - Sessões, e terminar aquela sessão.\n\nSe você acha que alguém acessou a sua conta contra a sua vontade, você pode habilitar a verificação em duas etapas nas configurações de Privacidade e Segurança.\n\nAtenciosamente,\nEquipe Telegram</string>
<string name="NotificationContactNewPhoto">%1$s atualizou a foto do perfil</string> <string name="NotificationContactNewPhoto">%1$s atualizou a foto do perfil</string>
<string name="NotificationInvitedToGroupByLink">%1$s entrou para o grupo %2$s via link de convite</string> <string name="NotificationInvitedToGroupByLink">%1$s entrou para o grupo %2$s via link de convite</string>
<string name="Reply">Responder</string> <string name="Reply">Responder</string>
@ -317,13 +339,22 @@
<string name="CopyLink">Copiar Link</string> <string name="CopyLink">Copiar Link</string>
<string name="ShareLink">Compartilhar Link</string> <string name="ShareLink">Compartilhar Link</string>
<string name="LinkInfo">Qualquer um com Telegram instalado poderá entrar no seu grupo abrindo este link.</string> <string name="LinkInfo">Qualquer um com Telegram instalado poderá entrar no seu grupo abrindo este link.</string>
<!--set admins view-->
<string name="SetAdminsTitle">Administradores de Conversas</string>
<string name="SetAdminsAll">Todos os membros são Administradores</string>
<string name="SetAdminsAllInfo">Todos os membros podem adicionar novos membros, editar o nome e a foto do grupo.</string>
<string name="SetAdminsNotAllInfo">Somente administradores podem adicionar e remover membros, editar nome foto do grupo.</string>
<!--group info view--> <!--group info view-->
<string name="SharedMedia">Mídia compartilhada</string> <string name="SharedMedia">Mídia compartilhada</string>
<string name="SETTINGS">Configurações</string> <string name="SETTINGS">Configurações</string>
<string name="AddMember">Adicionar membro</string> <string name="AddMember">Adicionar membro</string>
<string name="SetAdmins">Definir administradores</string>
<string name="DeleteAndExit">Apagar e sair do grupo</string> <string name="DeleteAndExit">Apagar e sair do grupo</string>
<string name="Notifications">Notificações</string> <string name="Notifications">Notificações</string>
<string name="KickFromGroup">Remover do grupo</string> <string name="KickFromGroup">Remover do grupo</string>
<string name="ConvertGroup">Atualizar para Supergrupo</string>
<string name="ConvertGroupAlert">Por favor note que os membros do grupo precisarão atualizar o aplicativo do Telegram até a última versão para verem seu supergrupo. Você tem certeza que deseja atualizar este grupo?</string>
<string name="ConvertGroupInfo"><![CDATA[<b>]]>Limite de membros atingido.<![CDATA[</b>]]>\n\nPara ir além do limite e ter funções adcionais, atualize para um supergrupo:\n\n• Supergrupos podem ter até %1$s\n• Novos membros veêm todo o histórico de conversas\n• Administradores deletam mensagens para todos\n• Notificações são silenciadas por padrão</string>
<!--contact info view--> <!--contact info view-->
<string name="ShareContact">Compartilhar</string> <string name="ShareContact">Compartilhar</string>
<string name="AddContact">Adicionar</string> <string name="AddContact">Adicionar</string>
@ -657,8 +688,8 @@
<string name="BotInvite">Adicionar Ao Grupo</string> <string name="BotInvite">Adicionar Ao Grupo</string>
<string name="BotSettings">Configurações</string> <string name="BotSettings">Configurações</string>
<string name="BotHelp">Ajuda</string> <string name="BotHelp">Ajuda</string>
<string name="BotStatusRead">tem acesso as mensagens</string> <string name="BotStatusRead">tem acesso às mensagens</string>
<string name="BotStatusCantRead">não tem acesso as mensagens</string> <string name="BotStatusCantRead">não tem acesso às mensagens</string>
<string name="BotInfoTitle">O que esse bot pode fazer?</string> <string name="BotInfoTitle">O que esse bot pode fazer?</string>
<string name="BotStart">COMEÇAR</string> <string name="BotStart">COMEÇAR</string>
<string name="BotUnblock">REINICIAR</string> <string name="BotUnblock">REINICIAR</string>
@ -677,6 +708,7 @@
<string name="Call">Ligar</string> <string name="Call">Ligar</string>
<string name="Copy">Copiar</string> <string name="Copy">Copiar</string>
<string name="Delete">Apagar</string> <string name="Delete">Apagar</string>
<string name="DeleteAndStop">Apagar e parar</string>
<string name="Forward">Encaminhar</string> <string name="Forward">Encaminhar</string>
<string name="Retry">Tentar novamente</string> <string name="Retry">Tentar novamente</string>
<string name="FromCamera">Câmera</string> <string name="FromCamera">Câmera</string>
@ -731,12 +763,13 @@
<string name="NoHandleAppInstalled">Você não possui um aplicativo que suporte o tipo de arquivo \'%1$s\', por favor instale um para continuar</string> <string name="NoHandleAppInstalled">Você não possui um aplicativo que suporte o tipo de arquivo \'%1$s\', por favor instale um para continuar</string>
<string name="InviteUser">Este usuário ainda não possui Telegram, deseja enviar um convite?</string> <string name="InviteUser">Este usuário ainda não possui Telegram, deseja enviar um convite?</string>
<string name="AreYouSure">Você tem certeza?</string> <string name="AreYouSure">Você tem certeza?</string>
<string name="AddToTheGroupTitle">Adicionar %1$s ao grupo %2$s?</string> <string name="AddToTheGroupTitle">Adcione %1$s ao chat %2$s?</string>
<string name="AddToTheGroupForwardCount">Número de mensagens antigas para encaminhar:</string> <string name="AddToTheGroupForwardCount">Número de mensagens antigas para encaminhar:</string>
<string name="AddToTheGroup">Adicionar %1$s no grupo?</string> <string name="AddToTheGroup">Adicionar %1$s no grupo?</string>
<string name="UserAlreadyInGroup">Este usuário já está neste grupo</string> <string name="UserAlreadyInGroup">Este usuário já está neste grupo</string>
<string name="ForwardMessagesTo">Encaminhar mensagem para %1$s?</string> <string name="ForwardMessagesTo">Encaminhar mensagem para %1$s?</string>
<string name="SendMessagesTo">Enviar mensagens para %1$s?</string> <string name="SendMessagesTo">Enviar mensagens para %1$s?</string>
<string name="SendContactTo">Enviar contato para %1$s?</string>
<string name="AreYouSureLogout">Você tem certeza que desejar sair?\n\nSaiba que você pode usar o Telegram em vários dispositivos de uma vez.\n\nLembre-se, sair apaga todos os seus Chats Secretos.</string> <string name="AreYouSureLogout">Você tem certeza que desejar sair?\n\nSaiba que você pode usar o Telegram em vários dispositivos de uma vez.\n\nLembre-se, sair apaga todos os seus Chats Secretos.</string>
<string name="AreYouSureSessions">Você tem certeza que deseja terminar todas as outras sessões?</string> <string name="AreYouSureSessions">Você tem certeza que deseja terminar todas as outras sessões?</string>
<string name="AreYouSureDeleteAndExit">Você tem certeza que apagar e sair do grupo?</string> <string name="AreYouSureDeleteAndExit">Você tem certeza que apagar e sair do grupo?</string>
@ -750,6 +783,7 @@
<string name="AreYouSureClearHistory">Você tem certeza que deseja limpar o histórico?</string> <string name="AreYouSureClearHistory">Você tem certeza que deseja limpar o histórico?</string>
<string name="AreYouSureDeleteMessages">Você tem certeza que deseja apagar %1$s?</string> <string name="AreYouSureDeleteMessages">Você tem certeza que deseja apagar %1$s?</string>
<string name="SendMessagesToGroup">Enviar mensagens para %1$s?</string> <string name="SendMessagesToGroup">Enviar mensagens para %1$s?</string>
<string name="SendContactToGroup">Enviar contato para %1$s?</string>
<string name="ForwardMessagesToGroup">Encaminhar mensagem para %1$s?</string> <string name="ForwardMessagesToGroup">Encaminhar mensagem para %1$s?</string>
<string name="FeatureUnavailable">Desculpe, esta funcionalidade não está disponível para seu país.</string> <string name="FeatureUnavailable">Desculpe, esta funcionalidade não está disponível para seu país.</string>
<string name="NoUsernameFound">Não há conta do Telegram com esse nome de usuário</string> <string name="NoUsernameFound">Não há conta do Telegram com esse nome de usuário</string>
@ -976,8 +1010,8 @@
<string name="formatterDay12H">h:mm a</string> <string name="formatterDay12H">h:mm a</string>
<string name="formatDateAtTime">%1$s às %2$s</string> <string name="formatDateAtTime">%1$s às %2$s</string>
<!--update text--> <!--update text-->
<string name="updateText">Plus Messenger para Android foi atualizado. Novidades na versão 3.2.6:\n\n- Novas animações e melhorias no visual\n- Suporte para novos emojis\n- Outras melhorias e resoluções de bugs</string> <string name="updateText">Plus Messenger para Android foi atualizado. Novidades na versão 3.3.1:\n\n- Os grupos agora podem ter múltiplos administradores com permissão para editar o nome e a imagem do grupo, adicionar e remover membros.\n- Os grupos que alcançarem 200 usuários podem ser transformados em supergrupos, que permitem até 1000 membros.\n- Os canais contam com um botão de compartilhamento rápido ao lado das mensagens.\n\nVocê pode ver mais sobre os supergrupos e sobre os demais assuntos no nosso blog:\nhttps://telegram.org/blog/supergroups</string>
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--> <!--Telegram+-->
<string name="TelegramForAndroid">Plus Messenger para Android</string> <string name="TelegramForAndroid">Plus Messenger para Android</string>
<string name="Theming">Temas</string> <string name="Theming">Temas</string>

View File

@ -108,7 +108,6 @@
<string name="ActionChannelChangedPhoto">Фото канала изменено</string> <string name="ActionChannelChangedPhoto">Фото канала изменено</string>
<string name="ActionChannelRemovedPhoto">Фото канала удалено</string> <string name="ActionChannelRemovedPhoto">Фото канала удалено</string>
<string name="ActionChannelChangedTitle">Имя канала изменено на un2</string> <string name="ActionChannelChangedTitle">Имя канала изменено на un2</string>
<string name="ActionChannelInvite">un1 добавил(а) вас на канал un2</string>
<string name="ChannelPublicLimitReached">Извините, вы создали слишком много публичных каналов. Вы можете либо удалить один из существующих, либо создать частный канал.</string> <string name="ChannelPublicLimitReached">Извините, вы создали слишком много публичных каналов. Вы можете либо удалить один из существующих, либо создать частный канал.</string>
<string name="ChannelModerator">Модератор</string> <string name="ChannelModerator">Модератор</string>
<string name="ChannelCreator">Создатель</string> <string name="ChannelCreator">Создатель</string>
@ -125,7 +124,6 @@
<string name="ChannelAdminsInfo">Вы можете добавлять администраторов для помощи в управлении каналом. Нажмите и удерживайте чтобы удалить администраторов.</string> <string name="ChannelAdminsInfo">Вы можете добавлять администраторов для помощи в управлении каналом. Нажмите и удерживайте чтобы удалить администраторов.</string>
<string name="ChannelJoinTo">Хотите присоединиться к каналу \'%1$s\'?</string> <string name="ChannelJoinTo">Хотите присоединиться к каналу \'%1$s\'?</string>
<string name="ChannelCantOpenPrivate">Извините, этот канал больше недоступен.</string> <string name="ChannelCantOpenPrivate">Извините, этот канал больше недоступен.</string>
<string name="ChannelAddToTitle">Добавить пользователя %1$s на канал %2$s?</string>
<string name="ChannelAddTo">Добавить пользователя %1$s на канал?</string> <string name="ChannelAddTo">Добавить пользователя %1$s на канал?</string>
<string name="ChannelUserLeftError">Извините, этот пользователь решил покинуть данную группу, поэтому вы не можете пригласить его обратно.</string> <string name="ChannelUserLeftError">Извините, этот пользователь решил покинуть данную группу, поэтому вы не можете пригласить его обратно.</string>
<string name="ChannelUserCantAdd">Извините, вы не можете добавить этого пользователя на каналы.</string> <string name="ChannelUserCantAdd">Извините, вы не можете добавить этого пользователя на каналы.</string>
@ -972,11 +970,11 @@
<string name="formatterDay24H">HH:mm</string> <string name="formatterDay24H">HH:mm</string>
<string name="formatterDay12H">h:mm a</string> <string name="formatterDay12H">h:mm a</string>
<string name="formatDateAtTime">%1$s в %2$s</string> <string name="formatDateAtTime">%1$s в %2$s</string>
<!--update text--> <!--update text--><!--
<string name="updateText">Telegram для Android обновлён. Новое в версии 3.2.6:\n\n- Новые анимации и множество визуальных усовершенствований\n- Поддержка новых эмодзи\n- Прочие улучшения и исправления ошибок</string> <string name="updateText">Telegram для Android обновлён. Новое в версии 3.2.6:\n\n- Новые анимации и множество визуальных усовершенствований\n- Поддержка новых эмодзи\n- Прочие улучшения и исправления ошибок</string>-->
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--> <!--Telegram+--><!--
<string name="updatePlusText">\n\nНовое в версии 3.2.6.2:\n\n- Теперь заголовок берёт цвет в списке недавних приложений Andriod\n- Увеличен размер списка упоминаний на экране чата\n- Теперь каналы можно перевести в беззвучный режим из основного экранаn\n- Добавлена настройка закругления аватара в заголовке экрана чата\n- Добавлена настройка цвета для уведомления печати в заголовке чата\n- Исправление ошибок</string> <string name="updatePlusText">\n\nНовое в версии 3.3.1.0:\n\n- Исправление ошибок</string>-->
<string name="TelegramForAndroid">Plus Messenger для Android</string> <string name="TelegramForAndroid">Plus Messenger для Android</string>
<string name="Theming">Кастомизация</string> <string name="Theming">Кастомизация</string>
<string name="colorHexInvalid">Неверный hex-код цвета!</string> <string name="colorHexInvalid">Неверный hex-код цвета!</string>

View File

@ -830,7 +830,7 @@
<string name="formatDateAtTime">%1$s %2$s</string> <string name="formatDateAtTime">%1$s %2$s</string>
<!--update text--><!-- <!--update text--><!--
<string name="updateText">Plus Messenger için temalar indirin ve uygulayın. Hergün yeni temalar ekleniyor:\n https://play.google.com/store/apps/details?id=es.rafalense.themes</string>--> <string name="updateText">Plus Messenger için temalar indirin ve uygulayın. Hergün yeni temalar ekleniyor:\n https://play.google.com/store/apps/details?id=es.rafalense.themes</string>-->
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--><!-- <!--Telegram+--><!--
<string name="updatePlusText"> <string name="updatePlusText">
\n\n3.2.2.1\'deki Yenilikler:\n\n- Artık duvarkağıdı direkt olarak sohbet ekranından değişebiliyor\n- Tema duvarkağıtlarının uygulama yönteminde geliştirmeler yapıldı\n- Eğer profil ekranında işaretlenmişse kullanıcı adı kopyalanabilir\n- Hata düzeltmeleri</string>--> \n\n3.2.2.1\'deki Yenilikler:\n\n- Artık duvarkağıdı direkt olarak sohbet ekranından değişebiliyor\n- Tema duvarkağıtlarının uygulama yönteminde geliştirmeler yapıldı\n- Eğer profil ekranında işaretlenmişse kullanıcı adı kopyalanabilir\n- Hata düzeltmeleri</string>-->

View File

@ -108,7 +108,6 @@
<string name="ActionChannelChangedPhoto">频道照片已变更</string> <string name="ActionChannelChangedPhoto">频道照片已变更</string>
<string name="ActionChannelRemovedPhoto">频道照片已删除</string> <string name="ActionChannelRemovedPhoto">频道照片已删除</string>
<string name="ActionChannelChangedTitle">频道名字变更为 un2</string> <string name="ActionChannelChangedTitle">频道名字变更为 un2</string>
<string name="ActionChannelInvite">un1 把你添加到了 un2 频道</string>
<string name="ChannelPublicLimitReached">很抱歉,你创建了太多公共频道。你可以创建一个私有频道或者先删除一个已有频道。</string> <string name="ChannelPublicLimitReached">很抱歉,你创建了太多公共频道。你可以创建一个私有频道或者先删除一个已有频道。</string>
<string name="ChannelModerator">代管员</string> <string name="ChannelModerator">代管员</string>
<string name="ChannelCreator">创建者</string> <string name="ChannelCreator">创建者</string>
@ -897,9 +896,9 @@
<string name="formatDateAtTime">%1$s 的 %2$s</string> <string name="formatDateAtTime">%1$s 的 %2$s</string>
<!--update text--><!-- <!--update text--><!--
<string name="updateText">Android 版的 Plus Messenger 已更新。最新版本 3.1 的新增功能有:\n\n- 在特定聊天中搜索消息内容。\n- 全新设计的附件选择菜单。从附件选择菜单中直接发送联系人资料或语音文件。\n- 改进的程序内媒体播放功能 YouTube, Vimoe, Soundcloud 等), 新播放器适用于大型语音文件。\n\n更多更新请查看\nhttps://telegram.org/blog/search-and-media</string>--> <string name="updateText">Android 版的 Plus Messenger 已更新。最新版本 3.1 的新增功能有:\n\n- 在特定聊天中搜索消息内容。\n- 全新设计的附件选择菜单。从附件选择菜单中直接发送联系人资料或语音文件。\n- 改进的程序内媒体播放功能 YouTube, Vimoe, Soundcloud 等), 新播放器适用于大型语音文件。\n\n更多更新请查看\nhttps://telegram.org/blog/search-and-media</string>-->
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--><!-- <!--Telegram+--><!--
<string name="updatePlusText">\n\n在 3.2.6.2 版的新功能:\n\n- 添加设置使用手机字体选项\n- 添加聊天/群组聊天内搜索聊天记录选项\n- 在设置/主题调整界面里添加标头颜色、标题颜色和标头图标颜色的设置\n- 添加主界面群组图标颜色的设置\n- 添加导航栏中头像大小的设置\n- 错误修复</string>--> <string name="updatePlusText">\n\n在 3.3.1.0 版的新功能:\n\n- 错误修复</string>-->
<string name="TelegramForAndroid">Plus Messenger for Android</string> <string name="TelegramForAndroid">Plus Messenger for Android</string>
<string name="Theming">主题调整</string> <string name="Theming">主题调整</string>
<string name="colorHexInvalid">无效的颜色代码!</string> <string name="colorHexInvalid">无效的颜色代码!</string>

View File

@ -108,7 +108,6 @@
<string name="ActionChannelChangedPhoto">頻道照片已變更</string> <string name="ActionChannelChangedPhoto">頻道照片已變更</string>
<string name="ActionChannelRemovedPhoto">頻道照片已移除</string> <string name="ActionChannelRemovedPhoto">頻道照片已移除</string>
<string name="ActionChannelChangedTitle">頻道名稱變更為 un2</string> <string name="ActionChannelChangedTitle">頻道名稱變更為 un2</string>
<string name="ActionChannelInvite">un1 將您加入到 un2 頻道</string>
<string name="ChannelPublicLimitReached">很抱歉,您已經建立了太多公開的頻道。首先,您可以選擇建立私人的頻道或是刪除您存在的頻道。</string> <string name="ChannelPublicLimitReached">很抱歉,您已經建立了太多公開的頻道。首先,您可以選擇建立私人的頻道或是刪除您存在的頻道。</string>
<string name="ChannelModerator">仲裁者</string> <string name="ChannelModerator">仲裁者</string>
<string name="ChannelCreator">建立者</string> <string name="ChannelCreator">建立者</string>
@ -125,7 +124,6 @@
<string name="ChannelAdminsInfo">您可以添加管理者以幫助您管理頻道。點擊不放可以移除管理者。</string> <string name="ChannelAdminsInfo">您可以添加管理者以幫助您管理頻道。點擊不放可以移除管理者。</string>
<string name="ChannelJoinTo">您想要加入「%1$s」頻道</string> <string name="ChannelJoinTo">您想要加入「%1$s」頻道</string>
<string name="ChannelCantOpenPrivate">很抱歉,這個頻道無法再被存取。</string> <string name="ChannelCantOpenPrivate">很抱歉,這個頻道無法再被存取。</string>
<string name="ChannelAddToTitle">將 %1$s 加入到 %2$s 頻道?</string>
<string name="ChannelAddTo">將 %1$s 加入到頻道?</string> <string name="ChannelAddTo">將 %1$s 加入到頻道?</string>
<string name="ChannelUserLeftError">很抱歉,該用戶決定離開群組,所以您無法再邀請此人回來這裡。</string> <string name="ChannelUserLeftError">很抱歉,該用戶決定離開群組,所以您無法再邀請此人回來這裡。</string>
<string name="ChannelUserCantAdd">很抱歉,您無法將此用戶加入到頻道。</string> <string name="ChannelUserCantAdd">很抱歉,您無法將此用戶加入到頻道。</string>
@ -946,11 +944,11 @@
<string name="formatterDay12H">a h:mm</string> <string name="formatterDay12H">a h:mm</string>
<string name="formatDateAtTime">於時間 %1$s %2$s</string> <string name="formatDateAtTime">於時間 %1$s %2$s</string>
<!--update text--><!-- <!--update text--><!--
<string name="updateText">Android 版的 Telegram 已經更新。在版本 3.2.0 中的新功能:\n\n- 引進頻道 用來將您的訊息向無限觀眾廣播的新方式 (取代舊式的廣播)。\n\n了解更多https://telegram.org/blog/channels</string> <string name="updateText">Android 版的 Telegram 已經更新。在版本 3.2.0 中的新功能:\n\n- 引進頻道 用來將您的訊息向無限觀眾廣播的新方式 (取代舊式的廣播)。\n\n了解更多https://telegram.org/blog/channels</string>-->
<string name="updateBuild">661</string>--> <string name="updateBuild">686</string>
<!--Telegram+--><!-- <!--Telegram+--><!--
<string name="updatePlusText"> <string name="updatePlusText">
\n\n在 3.2.6.2 版的新功能:\n\n- 新的模組在聊天畫面顯示擁有的大頭照\n- 加入新的泡泡邊緣 (感謝 Edwin Macalopu)\n- 錯誤修復</string>--> \n\n在 3.3.1.0 版的新功能:\n\n- 新的模組在聊天畫面顯示擁有的大頭照\n- 加入新的泡泡邊緣 (感謝 Edwin Macalopu)\n- 錯誤修復</string>-->
<string name="TelegramForAndroid">適用於 Android 的 Plus Messenger</string> <string name="TelegramForAndroid">適用於 Android 的 Plus Messenger</string>
<string name="Theming">自製佈景主題</string> <string name="Theming">自製佈景主題</string>
<string name="colorHexInvalid">無效的十六進位顏色代碼!</string> <string name="colorHexInvalid">無效的十六進位顏色代碼!</string>

View File

@ -4,6 +4,7 @@
<resources> <resources>
<string name="AppName">Plus Messenger</string> <string name="AppName">Plus Messenger</string>
<string name="AppNameBeta">Plus Messenger Beta</string>
<string name="ShortAppName">Plus</string> <string name="ShortAppName">Plus</string>
<string name="LanguageName">English</string> <string name="LanguageName">English</string>
<string name="LanguageNameInEnglish">English</string> <string name="LanguageNameInEnglish">English</string>
@ -61,7 +62,28 @@
<string name="MuteDisable">Disable</string> <string name="MuteDisable">Disable</string>
<string name="Hashtags">HASHTAGS</string> <string name="Hashtags">HASHTAGS</string>
<string name="Recent">RECENT</string> <string name="Recent">RECENT</string>
<string name="LinkPreview">Link preview</string>
<!--channels--> <!--channels-->
<string name="SetAsAdmin">Promote to admin</string>
<string name="DescriptionInfoMega">You can provide an optional description for your group.</string>
<string name="LeaveMega">Leave Group</string>
<string name="DeleteMega">Delete Group</string>
<string name="LeaveMegaMenu">Leave group</string>
<string name="DeleteMegaMenu">Delete group</string>
<string name="MegaDeleteInfo">You will lose all messages in this group.</string>
<string name="MegaAdminsInfo">You can add administrators to help you manage your group. Tap and hold to remove them.</string>
<string name="MegaDeleteAlert">Wait! Deleting this group will remove all members and all messages will be lost. Delete the group anyway?</string>
<string name="ActionCreateMega">Group created</string>
<string name="MegaAddedBy">un1 added you to this group</string>
<string name="MegaLeaveAlert">Are you sure you want to leave the group?</string>
<string name="GroupUserCantAdd">Sorry, you can\'t add this user to groups.</string>
<string name="GroupUserAddLimit">Sorry, this group is full.</string>
<string name="GroupUserLeftError">Sorry, this user decided to leave this group, so you cannot invite them back here.</string>
<string name="GroupUserCantAdmin">Sorry, too many adminstrators in this group.</string>
<string name="GroupUserCantBot">Sorry, too many bots in this group.</string>
<string name="ActionMigrateFromGroup">This group was upgraded to a supergroup</string>
<string name="ActionMigrateFromGroupNotify">%1$s was upgraded to a supergroup</string>
<string name="NoBlockedGroup">Blocked users are removed from the group and can only come back if invited by an admin. Invite links don\'t work for them.</string>
<string name="NewChannel">New Channel</string> <string name="NewChannel">New Channel</string>
<string name="EnterChannelName">Channel name</string> <string name="EnterChannelName">Channel name</string>
<string name="Comments">Comments</string> <string name="Comments">Comments</string>
@ -112,7 +134,6 @@
<string name="ActionChannelChangedPhoto">Channel photo changed</string> <string name="ActionChannelChangedPhoto">Channel photo changed</string>
<string name="ActionChannelRemovedPhoto">Channel photo removed</string> <string name="ActionChannelRemovedPhoto">Channel photo removed</string>
<string name="ActionChannelChangedTitle">Channel name changed to un2</string> <string name="ActionChannelChangedTitle">Channel name changed to un2</string>
<string name="ActionChannelInvite">un1 added you to the channel un2</string>
<string name="ChannelPublicLimitReached">Sorry, you have created too many public channels. You can either create a private channel or delete one of your existing channels first.</string> <string name="ChannelPublicLimitReached">Sorry, you have created too many public channels. You can either create a private channel or delete one of your existing channels first.</string>
<string name="ChannelModerator">Moderator</string> <string name="ChannelModerator">Moderator</string>
<string name="ChannelCreator">Creator</string> <string name="ChannelCreator">Creator</string>
@ -128,12 +149,12 @@
<string name="ChannelLinkInfo">Anyone who has Telegram installed will be able to join your channel by following this link.</string> <string name="ChannelLinkInfo">Anyone who has Telegram installed will be able to join your channel by following this link.</string>
<string name="ChannelAdminsInfo">You can add administrators to help you manage your channel. Tap and hold to remove admins.</string> <string name="ChannelAdminsInfo">You can add administrators to help you manage your channel. Tap and hold to remove admins.</string>
<string name="ChannelJoinTo">Do you want to join the channel \'%1$s\'?</string> <string name="ChannelJoinTo">Do you want to join the channel \'%1$s\'?</string>
<string name="ChannelCantOpenPrivate">Sorry, this channel is no longer accessible.</string> <string name="ChannelCantOpenPrivate">Sorry, this chat is no longer accessible.</string>
<string name="ChannelAddToTitle">Add %1$s to the channel %2$s?</string>
<string name="ChannelAddTo">Add %1$s to the channel?</string> <string name="ChannelAddTo">Add %1$s to the channel?</string>
<string name="ChannelUserLeftError">Sorry, this user decided to leave this group, so you cannot invite them back here.</string> <string name="ChannelUserLeftError">Sorry, this user decided to leave this channel, so you cannot invite them back here.</string>
<string name="ChannelUserCantAdd">Sorry, you can\'t add this user to channels.</string> <string name="ChannelUserCantAdd">Sorry, you can\'t add this user to channels.</string>
<string name="ChannelUserCantAdmin">Sorry, too many admins in this channel.</string> <string name="ChannelUserCantAdmin">Sorry, too many admins in this channel.</string>
<string name="ChannelUserCantBot">Sorry, too many bots in this channel.</string>
<string name="ChannelUserAddLimit">Sorry, you can only add the first 200 members to a channel. Note that an unlimited number of people may join via the channel\'s link.</string> <string name="ChannelUserAddLimit">Sorry, you can only add the first 200 members to a channel. Note that an unlimited number of people may join via the channel\'s link.</string>
<string name="ChannelAddedBy">un1 added you to this channel</string> <string name="ChannelAddedBy">un1 added you to this channel</string>
<string name="ChannelJoined">You joined the channel</string> <string name="ChannelJoined">You joined the channel</string>
@ -243,6 +264,7 @@
<string name="NobodyLikesSpam2">Sorry, you can only add mutual contacts to groups at the moment.</string> <string name="NobodyLikesSpam2">Sorry, you can only add mutual contacts to groups at the moment.</string>
<string name="NobodyLikesSpamUrl">https://telegram.org/faq#can-39t-send-messages-to-non-contacts</string> <string name="NobodyLikesSpamUrl">https://telegram.org/faq#can-39t-send-messages-to-non-contacts</string>
<string name="MoreInfo">More info</string> <string name="MoreInfo">More info</string>
<string name="ShareSendTo">Send to...</string>
<!--notification--> <!--notification-->
<string name="MessageLifetimeChanged">%1$s set the self-destruct timer to %2$s</string> <string name="MessageLifetimeChanged">%1$s set the self-destruct timer to %2$s</string>
<string name="MessageLifetimeChangedOutgoing">You set the self-destruct timer to %1$s</string> <string name="MessageLifetimeChangedOutgoing">You set the self-destruct timer to %1$s</string>
@ -318,13 +340,22 @@
<string name="CopyLink">Copy Link</string> <string name="CopyLink">Copy Link</string>
<string name="ShareLink">Share Link</string> <string name="ShareLink">Share Link</string>
<string name="LinkInfo">Anyone who has Telegram installed will be able to join your group by following this link.</string> <string name="LinkInfo">Anyone who has Telegram installed will be able to join your group by following this link.</string>
<!--set admins view-->
<string name="SetAdminsTitle">Chat Admins</string>
<string name="SetAdminsAll">All Members are Admins</string>
<string name="SetAdminsAllInfo">All members can add new members, edit name and photo of the group.</string>
<string name="SetAdminsNotAllInfo">Only admins can add and remove members, edit name and photo of the group.</string>
<!--group info view--> <!--group info view-->
<string name="SharedMedia">Shared Media</string> <string name="SharedMedia">Shared Media</string>
<string name="SETTINGS">Settings</string> <string name="SETTINGS">Settings</string>
<string name="AddMember">Add member</string> <string name="AddMember">Add member</string>
<string name="SetAdmins">Set admins</string>
<string name="DeleteAndExit">Delete and leave group</string> <string name="DeleteAndExit">Delete and leave group</string>
<string name="Notifications">Notifications</string> <string name="Notifications">Notifications</string>
<string name="KickFromGroup">Remove from group</string> <string name="KickFromGroup">Remove from group</string>
<string name="ConvertGroup">Upgrade to Supergroup</string>
<string name="ConvertGroupAlert">Please note that group members will need to update their Telegram apps to the latest version to see your supergroup. Are you sure you want to upgrade this group?</string>
<string name="ConvertGroupInfo"><![CDATA[<b>]]>Members limit reached.<![CDATA[</b>]]>\n\nTo go over the limit and get additional features, upgrade to a supergroup:\n\n• Supergroups can get up to %1$s\n• New members see the entire chat history\n• Admins delete messages for everyone\n• Notifications are muted by default</string>
<!--contact info view--> <!--contact info view-->
<string name="ShareContact">Share</string> <string name="ShareContact">Share</string>
<string name="AddContact">Add</string> <string name="AddContact">Add</string>
@ -678,6 +709,7 @@
<string name="Call">Call</string> <string name="Call">Call</string>
<string name="Copy">Copy</string> <string name="Copy">Copy</string>
<string name="Delete">Delete</string> <string name="Delete">Delete</string>
<string name="DeleteAndStop">Delete and stop</string>
<string name="Forward">Forward</string> <string name="Forward">Forward</string>
<string name="Retry">Retry</string> <string name="Retry">Retry</string>
<string name="FromCamera">From camera</string> <string name="FromCamera">From camera</string>
@ -732,12 +764,13 @@
<string name="NoHandleAppInstalled">You don\'t have applications that can handle the file type \'%1$s\', please install one to continue</string> <string name="NoHandleAppInstalled">You don\'t have applications that can handle the file type \'%1$s\', please install one to continue</string>
<string name="InviteUser">This user does not have Telegram yet, send an invitation?</string> <string name="InviteUser">This user does not have Telegram yet, send an invitation?</string>
<string name="AreYouSure">Are you sure?</string> <string name="AreYouSure">Are you sure?</string>
<string name="AddToTheGroupTitle">Add %1$s to the group %2$s?</string> <string name="AddToTheGroupTitle">Add %1$s to the chat %2$s?</string>
<string name="AddToTheGroupForwardCount">Number of last messages to forward:</string> <string name="AddToTheGroupForwardCount">Number of last messages to forward:</string>
<string name="AddToTheGroup">Add %1$s to the group?</string> <string name="AddToTheGroup">Add %1$s to the group?</string>
<string name="UserAlreadyInGroup">This user is already in this group</string> <string name="UserAlreadyInGroup">This user is already in this group</string>
<string name="ForwardMessagesTo">Forward messages to %1$s?</string> <string name="ForwardMessagesTo">Forward messages to %1$s?</string>
<string name="SendMessagesTo">Send messages to %1$s?</string> <string name="SendMessagesTo">Send messages to %1$s?</string>
<string name="SendContactTo">Send contact to %1$s?</string>
<string name="AreYouSureLogout">Are you sure you want to log out?\n\nNote that you can seamlessly use Telegram on all your devices at once.\n\nRemember, logging out kills all your Secret Chats.</string> <string name="AreYouSureLogout">Are you sure you want to log out?\n\nNote that you can seamlessly use Telegram on all your devices at once.\n\nRemember, logging out kills all your Secret Chats.</string>
<string name="AreYouSureSessions">Are you sure you want to terminate all other sessions?</string> <string name="AreYouSureSessions">Are you sure you want to terminate all other sessions?</string>
<string name="AreYouSureDeleteAndExit">Are you sure you want to delete and leave the group?</string> <string name="AreYouSureDeleteAndExit">Are you sure you want to delete and leave the group?</string>
@ -751,6 +784,7 @@
<string name="AreYouSureClearHistory">Are you sure you want to clear history?</string> <string name="AreYouSureClearHistory">Are you sure you want to clear history?</string>
<string name="AreYouSureDeleteMessages">Are you sure you want to delete %1$s?</string> <string name="AreYouSureDeleteMessages">Are you sure you want to delete %1$s?</string>
<string name="SendMessagesToGroup">Send messages to %1$s?</string> <string name="SendMessagesToGroup">Send messages to %1$s?</string>
<string name="SendContactToGroup">Send contact to %1$s?</string>
<string name="ForwardMessagesToGroup">Forward messages to %1$s?</string> <string name="ForwardMessagesToGroup">Forward messages to %1$s?</string>
<string name="FeatureUnavailable">Sorry, this feature is currently not available in your country.</string> <string name="FeatureUnavailable">Sorry, this feature is currently not available in your country.</string>
<string name="NoUsernameFound">There is no Telegram account with this username.</string> <string name="NoUsernameFound">There is no Telegram account with this username.</string>
@ -977,10 +1011,11 @@
<string name="formatterDay12H">h:mm a</string> <string name="formatterDay12H">h:mm a</string>
<string name="formatDateAtTime">%1$s at %2$s</string> <string name="formatDateAtTime">%1$s at %2$s</string>
<!--update text--> <!--update text-->
<string name="updateText">Plus Messenger for Android has been updated. New in version 3.2.6:\n\n- New animations and many visual improvements\n- Support for new emoji\n- Android 6.0 support (Now on Tap - Direct Share - Fingerprint support for Passcodes)\n- Other improvements and bug fixes</string> <string name="updateText">Plus Messenger for Android has been updated. New in version 3.3.1:\n\n- Groups can now have multiple administrators with the ability to edit the name and logo, and add and remove members.\n- Groups that have reached their capacity of 200 users can be upgraded to supergroups of up to 1,000 members.\n- Channels got a new Quick Share button right next to messages.\n\nMore about this update:\nhttps://telegram.org/blog/supergroups</string>
<string name="updateBuild">661</string> <string name="updateBuild">686</string>
<!--Telegram+--> <!--Telegram+-->
<string name="updatePlusText">\n\nNew in version 3.2.6.2:\n\n- Now header gets color in android recent apps list (lollipop and up)\n- Mention list size increased in chat screen\n- Now also channels can be muted from main screen\n- Added mod to set header avatar radius in chat screen\n- Added mod to set \'typing\' text color in chat header\n- Bug fixes</string> <string name="updatePlusText"></string><!--
<string name="updatePlusText">\n\nNew in version 3.3.1.0:\n\n- Bug fixes</string>-->
<string name="TelegramForAndroid">Plus Messenger for Android</string> <string name="TelegramForAndroid">Plus Messenger for Android</string>
<string name="Theming">Theming</string> <string name="Theming">Theming</string>
<string name="colorHexInvalid">Invalid color hex code!</string> <string name="colorHexInvalid">Invalid color hex code!</string>
@ -1046,6 +1081,8 @@
<string name="MuteColor">Mute color</string> <string name="MuteColor">Mute color</string>
<string name="SendLogs">Send logs</string> <string name="SendLogs">Send logs</string>
<string name="SendLogsEmpty">There aren\'t logs</string> <string name="SendLogsEmpty">There aren\'t logs</string>
<string name="ClearLogs">Clear logs</string>
<string name="ClearLogsMsg">logs deleted</string>
<string name="SendIcon">Send Icon</string> <string name="SendIcon">Send Icon</string>
<string name="HideMobile">Hide mobile number from menu</string> <string name="HideMobile">Hide mobile number from menu</string>
<string name="FloatingPencilColor">Floating pencil color</string> <string name="FloatingPencilColor">Floating pencil color</string>
@ -1141,4 +1178,5 @@
<string name="CommandColorCheck">Bot command color check</string> <string name="CommandColorCheck">Bot command color check</string>
<string name="CommandColor">Bot command color</string> <string name="CommandColor">Bot command color</string>
<string name="HighlightSearchColor">Highlight search color</string> <string name="HighlightSearchColor">Highlight search color</string>
<string name="ThemeUpdated">%s has been updated</string>
</resources> </resources>