"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "ts/model-types.d.ts" between
Signal-Desktop-1.35.2.tar.gz and Signal-Desktop-1.36.1.tar.gz

About: Signal-Desktop is a cross-platform encrypted messaging service (also available for mobile devices).

model-types.d.ts  (Signal-Desktop-1.35.2):model-types.d.ts  (Signal-Desktop-1.36.1)
import * as Backbone from 'backbone'; import * as Backbone from 'backbone';
import { GroupV2ChangeType } from './groups';
import { LocalizerType } from './types/Util'; import { LocalizerType } from './types/Util';
import { CallHistoryDetailsType } from './types/Calling';
import { ColorType } from './types/Colors'; import { ColorType } from './types/Colors';
import { ConversationType } from './state/ducks/conversations'; import { ConversationType } from './state/ducks/conversations';
import { CallingClass, CallHistoryDetailsType } from './services/calling';
import { SendOptionsType } from './textsecure/SendMessage'; import { SendOptionsType } from './textsecure/SendMessage';
import { SyncMessageClass } from './textsecure.d'; import { SyncMessageClass } from './textsecure.d';
interface ModelAttributesInterface { interface ModelAttributesInterface {
[key: string]: any; [key: string]: any;
} }
type DeletesAttributesType = { type DeletesAttributesType = {
fromId: string; fromId: string;
serverTimestamp: number; serverTimestamp: number;
skipping to change at line 29 skipping to change at line 30
declare class DeletesModelType extends Backbone.Model<DeletesAttributesType> { declare class DeletesModelType extends Backbone.Model<DeletesAttributesType> {
forMessage(message: MessageModelType): Array<DeletesModelType>; forMessage(message: MessageModelType): Array<DeletesModelType>;
onDelete(doe: DeletesAttributesType): Promise<void>; onDelete(doe: DeletesAttributesType): Promise<void>;
} }
type TaskResultType = any; type TaskResultType = any;
type MessageAttributesType = { type MessageAttributesType = {
id: string; id: string;
serverTimestamp: number; type?: string;
expirationTimerUpdate?: {
expireTimer: number;
source?: string;
sourceUuid?: string;
};
// Legacy fields for timer update notification only
flags?: number;
groupV2Change?: GroupV2ChangeType;
// Required. Used to sort messages in the database for the conversation timeli
ne.
received_at?: number;
// More of a legacy feature, needed as we were updating the schema of messages
in the
// background, when we were still in IndexedDB, before attachments had gone
to disk
// We set this so that the idle message upgrade process doesn't pick this mess
age up
schemaVersion: number;
serverTimestamp?: number;
sourceUuid?: string;
}; };
declare class MessageModelType extends Backbone.Model<MessageAttributesType> { declare class MessageModelType extends Backbone.Model<MessageAttributesType> {
id: string; id: string;
static updateTimers(): void; static updateTimers(): void;
getContact(): ConversationModelType | undefined | null; getContact(): ConversationModelType | undefined | null;
getConversation(): ConversationModelType | undefined | null; getConversation(): ConversationModelType | undefined | null;
getPropsForSearchResult(): any; getPropsForSearchResult(): any;
skipping to change at line 52 skipping to change at line 70
handleDeleteForEveryone( handleDeleteForEveryone(
doe: DeletesModelType, doe: DeletesModelType,
shouldPersist: boolean shouldPersist: boolean
): Promise<void>; ): Promise<void>;
} }
type ConversationTypeType = 'private' | 'group'; type ConversationTypeType = 'private' | 'group';
type ConversationAttributesType = { type ConversationAttributesType = {
id: string; id: string;
uuid?: string; type: ConversationTypeType;
e164?: string; timestamp: number;
// Shared fields
active_at?: number | null; active_at?: number | null;
draft?: string; draft?: string;
groupId?: string;
isArchived?: boolean; isArchived?: boolean;
lastMessage?: string; lastMessage?: string;
members?: Array<string>; name?: string;
needsStorageServiceSync?: boolean;
needsVerification?: boolean; needsVerification?: boolean;
profileFamilyName?: string | null;
profileKey?: string | null;
profileName?: string | null;
profileSharing: boolean; profileSharing: boolean;
storageID?: string; storageID?: string;
type: ConversationTypeType; storageUnknownFields: string;
unreadCount?: number; unreadCount?: number;
verified?: number;
version: number; version: number;
// Private core info
uuid?: string;
e164?: string;
// Private other fields
profileFamilyName?: string | null;
profileKey?: string | null;
profileName?: string | null;
verified?: number;
// Group-only
groupId?: string;
left: boolean;
groupVersion?: number;
// GroupV1 only
members?: Array<string>;
// GroupV2 core info
masterKey?: string;
secretParams?: string;
publicParams?: string;
revision?: number;
// GroupV2 other fields
accessControl?: {
attributes: number;
members: number;
};
avatar?: {
url: string;
path: string;
hash: string;
};
expireTimer?: number;
membersV2?: Array<GroupV2MemberType>;
pendingMembersV2?: Array<GroupV2PendingMemberType>;
};
export type GroupV2MemberType = {
conversationId: string;
role: number;
joinedAtVersion: number;
};
export type GroupV2PendingMemberType = {
addedByUserId: string;
conversationId: string;
timestamp: number;
}; };
declare class ConversationModelType extends Backbone.Model< type VerificationOptions = {
key?: null | ArrayBuffer;
viaContactSync?: boolean;
viaStorageServiceSync?: boolean;
viaSyncMessage?: boolean;
};
export declare class ConversationModelType extends Backbone.Model<
ConversationAttributesType ConversationAttributesType
> { > {
id: string; id: string;
cachedProps: ConversationType; cachedProps: ConversationType;
initialPromise: Promise<any>; initialPromise: Promise<any>;
messageRequestEnum: typeof SyncMessageClass.MessageRequestResponse.Type; messageRequestEnum: typeof SyncMessageClass.MessageRequestResponse.Type;
addCallHistory(details: CallHistoryDetailsType): void; addCallHistory(details: CallHistoryDetailsType): void;
applyMessageRequestResponse( applyMessageRequestResponse(
response: number, response: number,
options?: { fromSync: boolean } options?: { fromSync: boolean; viaStorageServiceSync?: boolean }
): void; ): void;
cleanup(): Promise<void>; cleanup(): Promise<void>;
disableProfileSharing(): void; disableProfileSharing(options?: { viaStorageServiceSync?: boolean }): void;
dropProfileKey(): Promise<void>; dropProfileKey(): Promise<void>;
enableProfileSharing(options?: { viaStorageServiceSync?: boolean }): void;
generateProps(): void; generateProps(): void;
getAccepted(): boolean; getAccepted(): boolean;
getAvatarPath(): string | undefined; getAvatarPath(): string | undefined;
getColor(): ColorType | undefined; getColor(): ColorType | undefined;
getName(): string | undefined; getName(): string | undefined;
getNumber(): string; getNumber(): string;
getProfileName(): string | undefined; getProfileName(): string | undefined;
getProfiles(): Promise<Array<Promise<void>>>; getProfiles(): Promise<Array<Promise<void>>>;
getRecipients: () => Array<string>; getRecipients: () => Array<string>;
getSendOptions(options?: any): SendOptionsType | undefined; getSendOptions(options?: any): SendOptionsType | undefined;
getTitle(): string; getTitle(): string;
idForLogging(): string; idForLogging(): string;
debugID(): string;
isFromOrAddedByTrustedContact(): boolean; isFromOrAddedByTrustedContact(): boolean;
isBlocked(): boolean;
isMe(): boolean;
isPrivate(): boolean;
isVerified(): boolean; isVerified(): boolean;
maybeRepairGroupV2(data: {
masterKey: string;
secretParams: string;
publicParams: string;
}): void;
queueJob(job: () => Promise<void>): Promise<void>;
safeGetVerified(): Promise<number>; safeGetVerified(): Promise<number>;
setProfileKey(profileKey?: string | null): Promise<void>; setArchived(isArchived: boolean): void;
setProfileKey(
profileKey?: string | null,
options?: { viaStorageServiceSync?: boolean }
): Promise<void>;
setProfileAvatar(avatarPath: string): Promise<void>;
setUnverified(options: VerificationOptions): Promise<TaskResultType>;
setVerified(options: VerificationOptions): Promise<TaskResultType>;
setVerifiedDefault(options: VerificationOptions): Promise<TaskResultType>;
toggleVerified(): Promise<TaskResultType>; toggleVerified(): Promise<TaskResultType>;
unblock(): boolean | undefined; block(options?: { viaStorageServiceSync?: boolean }): void;
unblock(options?: { viaStorageServiceSync?: boolean }): boolean;
updateE164: (e164?: string) => void; updateE164: (e164?: string) => void;
updateLastMessage: () => Promise<void>; updateLastMessage: () => Promise<void>;
updateUuid: (uuid?: string) => void; updateUuid: (uuid?: string) => void;
wrapSend: (sendPromise: Promise<any>) => Promise<any>; wrapSend: (sendPromise: Promise<any>) => Promise<any>;
} }
declare class ConversationModelCollectionType extends Backbone.Collection< declare class ConversationModelCollectionType extends Backbone.Collection<
ConversationModelType ConversationModelType
> { > {
resetLookups(): void; resetLookups(): void;
 End of changes. 21 change blocks. 
16 lines changed or deleted 111 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)