Compare commits

...
Author SHA1 Message Date
Andrea Maria Piana 5edbd0f31c Update snx/synth contract 2020-10-06 12:13:23 +02:00
andrey 9f0ba0f67e fixed custom tokens 2020-10-06 11:38:54 +02:00
andrey 4a0ad12f3a fixed keycard tokens 2020-10-06 10:44:21 +02:00
andrey e52706a48e fix lint 2020-10-06 09:25:39 +02:00
andrey 5d4f48662a do not request tokens for new account 2020-10-06 08:20:48 +02:00
andrey 619c589bc8 update token balances and prices when selecting token 2020-10-06 07:42:26 +02:00
andrey 31e18663bd fix token balances for account creation 2020-10-05 20:12:08 +02:00
jakub 2a21b6c142 fix availability of INFURA_TOKEN for Android build
The env variable `INFURA_TOKEN` is used at build time of JS bundle, not
the final APK file. We never passed the `secretsFile` to the
derivation for JS bundle so it never saw the `INFURA_TOKEN`.

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-10-05 16:41:09 +02:00
andrey e1cbd3936f fix init wallet 2020-10-05 16:19:06 +02:00
andrey 99c6aa8512 fix js object 2020-10-05 14:48:50 +02:00
Andrea Maria Piana 2ad863a854 Bump version to 1.7.2 2020-10-05 13:11:42 +02:00
andrey c7ba1dea21 do not show zeros for token balances, and fetch all tokens only when creating new account 2020-10-05 13:10:08 +02:00
Andrea Maria Piana e4a65b3a23 Fix infura token
Setting a top-level closure-defines does not have any effect,
it needs to be for some reason inside each environment.
2020-10-05 13:08:50 +02:00
Andrea Maria Piana 385bf0d023 Add hotfix for wallet balance 2020-10-05 13:02:14 +02:00
Andrea Maria Piana 2d4638ab7f Fix migration when interrupted 2020-10-01 14:40:43 +02:00
andrey e40664533d override custom tokens
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-25 14:05:54 +02:00
Churikova Tetiana f152f8156f disable collectible e2e
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-25 14:05:53 +02:00
andrey b206a4e955 [#11218] Hard code fix for SUPR NFT support
Drop collectibles details support
2020-09-25 14:05:51 +02:00
andrey a18c429fee add images
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-25 14:05:51 +02:00
andrey 420e3f3586 [#11222] Add aUSDC token and optimize search for Aave (LEND) (aka Ethlend) 2020-09-25 14:05:50 +02:00
andrey 1c6da59611 1.7.0 2020-09-23 18:17:46 +02:00
andrey d9bac4a493 [#10667] Upgrade eth-phishing-detect library
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-23 18:17:06 +02:00
jinhojang6 ebf3016644 Update translation
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-23 18:06:42 +02:00
Roman Volosovskyi 345ae359aa [#11179] Nicknames in mention suggestions 2020-09-23 18:34:03 +03:00
Churikova Tetiana b8298dce44 e2e fixes
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-09-23 14:56:31 +02:00
Gheorghe Pinzaru 1969f9dfe0 Parse childrens in reply text
Fixes #11161

Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-23 07:43:44 +02:00
andrey 8eed842c62 [#11136] Warning to users sending ERC20 directly to smart contract
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-22 17:24:36 +02:00
andrey b32367a9b2 [#11185] Add UNI, COMP, AAVE, BAL, AKRO tokens
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-22 16:46:27 +02:00
andrey 7fb243f9f1 [#10060] Wrong ERC20 decimal rounding in "Set max"
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-22 16:02:56 +02:00
andrey 6b08194a19 [#11194] Change #status-spanish to #status-espanol
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-22 14:34:13 +02:00
Roman Volosovskyi 55278828e6 Update mention suggestions on selection change 2020-09-22 14:40:00 +03:00
andrey 99755d08e9 fix labels 2020-09-22 12:10:56 +02:00
andrey e95025333f fix android
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-22 10:23:35 +02:00
andrey ff790d4152 wallet favourites 2020-09-22 10:23:26 +02:00
Churikova Tetiana 6454df4734 e2e wallet fixes
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-22 10:22:12 +02:00
andrey 25dbf1fd61 [#9484] Reintroduce back collapsing of long messages in chats
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-21 18:05:25 +02:00
Roman Volosovskyi 0448edb509 Highlighted mentions in input 2020-09-21 13:10:54 +03:00
Churikova Tetiana 44e3076022 nightly e2e fixes
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-09-18 17:30:03 +02:00
Roman Volosovskyi 1009b71908 [#11160] Hide blocked users from mention suggestions 2020-09-17 22:32:58 +03:00
Roman Volosovskyi 80faac0ca7 [#11152] Resolve self mentions in group chat 2020-09-17 17:19:24 +03:00
Roman Volosovskyi b43f9e0dfd [#11173] Open profile on tapping self mention 2020-09-17 17:17:25 +03:00
Gheorghe Pinzaru 20b5ad9ebb Always use waku
Signed-off-by: Andrea Maria Piana <andrea.maria.piana@gmail.com>
2020-09-17 15:19:32 +02:00
Andrea Maria Piana e2071dc968 [Fixes: #11170] Move some pn settings to advanced
Signed-off-by: Andrea Maria Piana <andrea.maria.piana@gmail.com>
2020-09-17 15:07:53 +02:00
Serhy 1b1f3c4c9f e2e fix
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-16 18:08:30 +02:00
andrey 889d4c16a4 [#11163] No margin between "Block this user" button and main tabs panel on user profile view on iOS 2020-09-16 18:08:17 +02:00
Serhy ae0504cbfa Update test to copy formatted text messages
Signed-off-by: Serhy <sergii@status.im>
2020-09-16 18:28:46 +03:00
Volodymyr Kozieiev a95520067f Added ui for asking webview page permissions
Signed-off-by: Volodymyr Kozieiev <vkjr.sp@gmail.com>
2020-09-16 12:17:45 +03:00
Churikova Tetiana 56aec16793 nicknames e2e
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-09-15 18:04:52 +02:00
andrey 0594548617 [#11150] Chat icons are black in dark mode
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-15 14:30:54 +02:00
Gheorghe Pinzaru f7ec945c56 Force transparent color for timestamp android
Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-09-15 10:00:57 +03:00
jinhojang6 13e46c2fb0 Update translation
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-09-14 17:45:08 +02:00
andrey 301f1c8cf2 fix tokens validation
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-14 16:06:52 +02:00
andrey 1e5288a016 fix local nicknames 2020-09-14 12:22:46 +02:00
andrey 59e226bab2 fix local names , mute chat translation, replace null crash
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-14 11:58:45 +02:00
Churikova Tetiana 32cb09c9c6 fix some false failures
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-09-11 16:29:04 +02:00
Roman Volosovskyi 16fecc2ac6 Mentions suggestions 2020-09-10 22:07:56 +03:00
Andrey Shovkoplyas 0675d0d8d7 ios pn
Signed-off-by: Andrea Maria Piana <andrea.maria.piana@gmail.com>
2020-09-10 14:12:18 +02:00
Roman Volosovskyi f9df0f367f Get rid of form-2 subs in defview 2020-09-10 13:58:02 +03:00
Roman Volosovskyi 5aa33fc9c0 [mentions] Fix mention appearance in reply and quoted message 2020-09-10 12:51:34 +03:00
Churikova Tetiana 754b826629 accept agreement remove + group invite e2e
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-09-10 11:35:36 +02:00
Roman Volosovskyi 72daf93a75 [mentions] Open profile tab instead of user profile view on pressing own mention 2020-09-08 16:23:23 +03:00
andrey 89ad4f59d0 [#10179] Create invite link for group chat
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-07 13:32:24 +02:00
andrey 4304a5dd97 [#11046] Add local contact names
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-07 11:42:35 +02:00
Churikova Tetiana fea916590a marks and new checks in e2e
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-09-04 17:58:34 +02:00
jinhojang6 1a98219690 Update translations
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-09-04 17:56:51 +02:00
Serhy 3181a7dc20 E2e tests for audio message
Signed-off-by: Serhy <sergii@status.im>
2020-09-04 18:29:39 +03:00
Churikova Tetiana fed52fe309 new e2e and GH report changes
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-09-02 20:21:30 +02:00
jakub eac77f84c2 nix: upgrade nixpkgs
Significant updates:
- Git: `2.25.1` to `2.28.0`
- Make: `4.2.1` to `4.3`
- Glibc: `2.30` to `2.31`
- PatchElf: `0.9` to `0.11`
- GoLang: `1.14.0` to `1.14.7`
- NodeJS: `v12.16.2` to `v12.18.3`
- Clojure: `1.10.1.507` to `1.10.1.645`
- OpenJDK: `8u242-b08` to `8u265-ga`
- GoMobile: `20200329` to `20200622`

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-09-02 18:06:23 +02:00
Nathan Handler 080584dc2e Add Orchid ERC-20 Token (OXT)
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-02 14:44:12 +02:00
andrey be25ecd4ea [#10974] ENS resolving for IPNS names.
Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-02 14:39:41 +02:00
Александар Симић 2be70cca9a Aligning react versions
When starting the project the following would be spat out:

NPM dependency "react" has installed version "16.11.0"

"16.13.0" was required by jar:file:/Users/alex/.m2/repository
/reagent/reagent/0.10.0/reagent-0.10.0.jar!/deps.cljs

I've bumped up the version in package.json to to match the one being
pulled in by reagent.

Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-02 12:44:26 +02:00
Александар Симић b2a79b3e89 Update nREPL to the latest stable
With the update of Emacs CIDER 0.26.1, it expects to have the latest
cider-nrepl dependency to be at 0.25.3 otherwise it throws an error
when connecting to the project's REPL.

Signed-off-by: andrey <motor4ik@gmail.com>
2020-09-02 11:27:52 +02:00
Gheorghe Pinzaru fdf8d11913 Use monospace font for address and public-key
Swap monospace header

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-31 15:51:39 +03:00
Churikova Tetiana 399be0686c e2e enabled
Signed-off-by: andrey <motor4ik@gmail.com>
2020-08-31 10:52:47 +02:00
andrey 0cb554f5c6 [#11113] Can't send image without description in 1-1 and group chats 2020-08-31 10:52:28 +02:00
jinhojang6 2901f4c7cf Update translations
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-08-31 09:36:41 +02:00
Volodymyr Kozieiev 0ab227eef8 Restrict message size on input
Signed-off-by: Volodymyr Kozieiev <vkjr.sp@gmail.com>
2020-08-27 12:53:04 +03:00
Gheorghe Pinzaru 17c408bd06 Use different acquisition gateway based on chain
Do not persist empty tx

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-26 14:15:10 +03:00
Churikova Tetiana 716c968a23 new e2e + accessibility
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-08-25 16:44:05 +02:00
Gheorghe Pinzaru 8adc32a5c9 Simplify tabbar animation
Fixes #11086

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-25 10:17:45 +03:00
Roman Volosovskyi 2934de9b8c [mentions] Replace all mentions with public keys before sending message 2020-08-24 21:29:12 +03:00
Gheorghe Pinzaru 001789f761 Update translation strings for referrals
Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-24 11:28:21 +03:00
Gheorghe Pinzaru 8d8057036a Hide placeholder timestamp with opacity
Fixes #11084

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-24 11:27:37 +03:00
Churikova Tetiana 151ef4a952 e2e false failures fixes
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-08-20 14:02:00 +02:00
andrey 9b0bf60e60 1.6.0 2020-08-20 13:51:05 +02:00
Volodymyr Kozieiev 6bef1182c6 Subheader generation refactored for better performance
Signed-off-by: Volodymyr Kozieiev <vkjr.sp@gmail.com>
2020-08-20 14:21:09 +03:00
Gheorghe Pinzaru f17b401bbc Update UI for referrals flow
Cleanup http events

Add loaders

Add dapp flow

Fix tests

Fix dapp success event

Hide reward based on referrals metadata

New flows

Terms link

TX watcher event

Do not show success popup

Use new rewardable field from backend

Fix referral pulling

Update copy

Translate advertiser modal

Move modal styles into style ns

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-20 13:44:12 +03:00
Gheorghe Pinzaru 25721688db Debounce next in onboarding
Fixes #11043

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-20 13:26:27 +03:00
Churikova Tetiana 485dd99e52 fix and universal QR e2e
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-08-19 17:18:26 +02:00
Gheorghe Pinzaru c644ab3501 Resolve contract by ens name
Do not show referrals if contract is not available

Do not check contract for referral accept

Rename invite event namespace require

Remove dispatch from raw subs

Do nothing if there is no contract

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-19 17:10:27 +03:00
Volodymyr Kozieiev ac4f65be97 Fix crash when passcode disabled
Signed-off-by: Volodymyr Kozieiev <vkjr.sp@gmail.com>
2020-08-18 18:35:46 +03:00
Gheorghe Pinzaru b737051e3c Use the new intent link for private chat
Fixes #11080

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-18 16:15:32 +03:00
Gheorghe Pinzaru 1e7061acc2 Fix topbar in new contact
Fixes #11091

Fix more nav handlers keys

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-18 15:47:26 +03:00
jinhojang6 cc0076048d Update translations
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-08-18 14:33:15 +02:00
Andrea Maria Piana e52f9fa43f upgrade status-go & always call start/stop methods
Signed-off-by: Andrea Maria Piana <andrea.maria.piana@gmail.com>
2020-08-18 14:16:15 +02:00
Churikova Tetiana d5fc93aa55 fixes for e2e + new ids for elements
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-08-18 12:38:48 +02:00
Roman Volosovskyi c2277cbbe5 [#9986] Allow to disable fetching of tx history on mobile network 2020-08-15 21:34:37 +03:00
Churikova Tetiana d22a87b77c e2e fixes + e2e reaction
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-08-14 18:08:24 +02:00
Gheorghe Pinzaru 4e44bed8d6 Replace all usage of topbar with Quo
QR

Invert border boolean

Update e2e

Fix another e2e

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-14 14:22:40 +03:00
Gheorghe Pinzaru 62fe9f3d6a Clear home filter when opening chats
Fixes #11015 Fixes #11013

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-12 17:45:40 +03:00
Churikova Tetiana f128c0ceed new e2e and fixes
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-08-11 18:12:21 +02:00
Roman Volosovskyi 7d19de4e69 [mentions] Open profile on pressing mention in message 2020-08-11 13:10:04 +03:00
Gheorghe Pinzaru feb8dfce07 Enable Quo Preview in dev app
Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-11 11:21:54 +03:00
Gheorghe Pinzaru 9c37eac6f4 Use i18n for biometric auth types
Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-11 10:59:15 +03:00
Gheorghe Pinzaru 793579885a Add universal QR scanner via common router
Rename events

Add router to handle all links

Use router in add new chat

Unify universal link and universal qr with router

Add icon for universal scanner

Update tests

Now routing is tested in routing PR

lint

Cleanup

QA fixes

Scan own profile

Handle more EIP

Fix wallet scanner

Fix stack for view profile in UL

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-11 10:24:15 +03:00
andrey 2d8b0107e3 replace camera library
Signed-off-by: andrey <motor4ik@gmail.com>
2020-08-10 17:54:14 +02:00
Gheorghe Pinzaru 7bb7b48db7 Fix chat text input animation lags
Remove picker panel from input

Clean pan state

Fixes #11031

Do not use pan state on android

iOs panel switching do not change height

Revert "Remove picker panel from input"

This reverts commit 0ab2c1544b70f8c491424376268f572696bd284a.

Change reactions space keeper method

Audio

Do not use accessory view on Android

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-10 16:40:50 +03:00
jakub eeff44eea7 ci: fix Android release builds not splitting ABIs
This was caused by Groovy script logic not checking `params.BUILT_TYPE`.

Related: https://github.com/status-im/status-react-jenkins/pull/14

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-08-10 14:48:23 +02:00
andrey f9fb4d6974 eip-1193 fix
Signed-off-by: andrey <motor4ik@gmail.com>
2020-08-10 11:00:32 +02:00
jakub 68722340c9 nix: add missing args to gcroots.sh script
This should fix the following error showing up on MacOS:
```
error: assertion ((__lessThan  0)  ((builtins).stringLength  watchmanSockPath))
failed at /Users/jenkins/repos/status-react/nix/mobile/android/watchman.nix:8:9
```
Which was caused by flags like `--argstr` not being passed.

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-08-06 15:12:37 +02:00
jakub f904d7b543 nix: add --console=plain to gradle call
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-08-06 14:34:07 +02:00
jakub 7a80eca73c jenkin: fix GitHub releases
Specifically filenames and the diff link.

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-08-06 14:28:21 +02:00
jakub 2161192e76 nix: simplify build of gomobile
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-08-06 14:28:15 +02:00
Gheorghe Pinzaru 0319854e83 Home show search when input is focused or has content
Fixes #11017

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-06 13:55:39 +03:00
Churikova Tetiana dd67533ecd regression e2e fix
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-08-06 12:53:01 +02:00
Gheorghe Pinzaru 2371dcbc60 Show gfycat in new chat search
fixes #11027

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-06 09:58:29 +03:00
Gheorghe Pinzaru 72726e2b0b Fix ens name hash exception for bad names
Fixes #11022

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-06 09:17:20 +03:00
jakub 95997530c6 jenkins: increase iOS build timeout to 25 minutes
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-08-04 10:34:32 +02:00
jakub 7c0488372d upgrade Gems, Fastlane from 2.146.1 to 2.154.0
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-08-04 09:25:52 +02:00
andrey 3419dc3cbe 1.5.0 2020-08-03 15:34:05 +02:00
Volodymyr Kozieiev d5015e4d25 Switched to updated version of WebView that asks for permissions
Signed-off-by: Volodymyr Kozieiev <vkjr.sp@gmail.com>
2020-08-03 15:51:34 +03:00
Gheorghe Pinzaru 3c42360b30 Add referral program under feature flag
Add acquisition backend methods

Init referrals sharing UI

Add invite on home screen

Use i18n for strings

Lint

Update status go

Pull acquisition contract to get SNT amount

Use new invite component

f pulling

go

Use screen instead of bottom sheet

Handle android install referrer

Post referrer to backend if present

go go

Add async storage for referral decisions

Update with the stage backend

Update contract methods

Modal

UI

Full handling of advertiser type

UI

test

UI

Handle with universal link

Allow multiple acquisition per installation

Fix android bottom sheet

Do not call service if no click-id received

Disable invite in release

Parse query params for referrer

Adapt UI changes

Add push notification

update deps

Mock react-native-push-notification

Request push notifications permission on press accept

Store transaction to local storage and load it back on login

Separate acquisition into smaller ns

Add chat invite

Get referrer only on first install

fix string

Fix firebase crash

Handle outdate click-id

Cleanup business logic

Update contract

Revert pn

Minor update to advertiser modal copy

OLD -  Welcome to Status! Here is some crypto to get you started
NEW - Here’s some crypto to get you started! Use it to get stickers, an ENS name and try dapps

OLD - By accepting you agree to the starter pack
NEW - By accepting you agree to the referral program

upgrade status-go

Add mainnet

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-08-03 15:25:34 +03:00
Churikova Tetiana d0ce6f11d8 align e2e with reactions
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-07-31 14:56:57 +02:00
Gheorghe Pinzaru 1c308c2d01 Emoji reactions
Signed-off-by: Andrea Maria Piana <andrea.maria.piana@gmail.com>
2020-07-31 13:43:10 +02:00
jakub 933c0f8f8c nix: allow XCode versions 11.5 and higher
This is kinda hacky, but is simple enough since the version check uses grep.

For details see:
https://github.com/status-im/nixpkgs/blob/status-mods/pkgs/development/mobile/xcodeenv/compose-xcodewrapper.nix

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-07-31 13:04:47 +02:00
jinhojang6 8b99e992ad Update translations
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-07-31 11:15:22 +02:00
Roman Volosovskyi e96fc90199 [#10976] Fix crash on kk login with enabled fingerprint 2020-07-30 21:11:02 +03:00
Gheorghe Pinzaru 8652f899e0 [#10988] Add entry point to start new chat from search results
Fixes #10988

Allow public key and filter public chats

Make toolbar width 100

Clear new identity from search

QA issues fix

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-30 13:47:34 +03:00
Churikova Tetiana 56364ea70c e2e for PN and set max
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-07-29 17:58:39 +02:00
jakub 788d0d5cc5 add ANDROID_APK_SIGNED to make unsigned builds for F-Droid
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-07-29 10:12:38 +02:00
jakub 517a1be27c nix: disable Gradle daemon for builds
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-07-29 10:12:31 +02:00
jakub 8bb99743a7 nix: set GRADLE_USER_HOME to a temp dir
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-07-29 10:12:31 +02:00
jakub 0be5f5d8d0 nix: enable build-use-sandbox for Android
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-07-29 10:12:30 +02:00
tbenr 86700f2b5c audio messages
Signed-off-by: Andrea Maria Piana <andrea.maria.piana@gmail.com>
2020-07-29 10:09:31 +02:00
andrey 2cc8c9822f image reply fix
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-29 09:55:36 +02:00
andrey a968149ecc fix scan qr window
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-29 09:55:03 +02:00
Roman Volosovskyi 10a814764d [#10195] Delete multiaccount 2020-07-28 15:42:40 +03:00
andrey 4254dbcb26 [#10975] Missing translation on Keycard login page
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-28 11:27:39 +02:00
andrey 6c5daaa1c8 set max button in dark mode
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-27 18:25:42 +02:00
jinhojang6 ceb09dc0e7 Update translations
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-27 08:29:29 +02:00
Gheorghe Pinzaru 5b5096a6d7 Shrink left button in toolbar to not overflow
Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-24 18:01:52 +03:00
Gheorghe Pinzaru 729a35d830 Fix parens on intro screens
Fixes #10979

Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-07-23 13:23:53 +02:00
Churikova Tetiana fb9ab82d7b sign_in keycard e2e fix
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-07-23 11:41:19 +02:00
Dean Eigenmann f8af5a51be Update views.cljs
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-07-22 16:36:45 +02:00
Churikova Tetiana f057d527b5 fix 22.07.20 nightly failures
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-07-22 15:39:44 +02:00
Gheorghe Pinzaru 3b17a46bf8 Allow nested touchable in list item
Fixes #10924

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-22 15:51:50 +03:00
Serhy afb4e9fdb9 Add e2e test for PN
Signed-off-by: Serhy <sergii@status.im>
2020-07-21 12:30:04 +03:00
Gheorghe Pinzaru e8fca7ce68 Add interactive dismiss and new input UI
New input UI

Inverse panel height calculation

Remove old chat input

Better animations

fix for pasting text

Add buttons accessibility

Fix dark mode

Update react navigation to fix the keyboard issues

Force close bottom sheet

Unmount android bottom sheet when not visible

Reset bottom sheet height android

more fixes

more fixes

Add hidden audio icon

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-20 12:21:47 +03:00
Gheorghe Pinzaru 6fcb426a71 Disabled next in password screen
Fixes #10965

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-20 12:17:30 +03:00
Gheorghe Pinzaru 4f135292a5 Fix UI issues in backup seed phrase
Fixes #10964
2020-07-20 12:17:19 +03:00
Gheorghe Pinzaru 0f07f3eecb Update image resizer
Do not resize images in camera roll

request permission on camera roll

fix images e2e

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-20 11:54:31 +03:00
jinhojang6 4e5848ee6f Update translations
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-07-16 11:43:46 +02:00
Gheorghe Pinzaru 923beb5f26 Disable by default list item animations on android
Use highlight for touchable feedback

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-16 11:17:51 +03:00
Roman Volosovskyi 292df1439c [#10928] Always show blocked users 2020-07-15 21:27:32 +03:00
Churikova Tetiana cd4b2110c6 e2e for contact view
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-07-15 20:22:27 +02:00
jakub 9ce786c9fb nix: fix conditional that selects .env.e2e for ABI=x86 builds
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-07-15 16:37:45 +02:00
Roman Volosovskyi 618b1f81e2 [#10914] Show proper username in chat on opening from background 2020-07-15 15:07:14 +03:00
Gheorghe Pinzaru b7bc7c4e5d Don't re-open bottom sheet if now closing
Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-15 11:40:32 +03:00
Gheorghe Pinzaru fa4968f22c Fix password position in wallet new account
Fixes #10921

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-15 11:39:21 +03:00
Gheorghe Pinzaru 0adc047f05 Fix missing i18n
fixes #10945

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-15 11:38:28 +03:00
Gheorghe Pinzaru 5c05174604 Merge password screens
Update e2e

Small UX feedback changes

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-15 11:28:02 +03:00
Gheorghe Pinzaru df9062475c Extend security masked data protocol 2020-07-15 11:25:10 +03:00
Serhy f5675b640d Fix scroll and key to locate eth
Signed-off-by: Serhy <sergii@status.im>
2020-07-14 20:11:58 +03:00
Churikova Tetiana cd04acde3a e2e for separate keystore
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-07-14 16:08:47 +02:00
Roman Volosovskyi 15cbec07e9 [keycard] Rename all "hardwallet" occurencies to "keycard"
Previously we used both "keycard" and "hardwallet" names for stuff
related to keycard. It can be confusing as "hardwallet" might be used
for other hardwallets in future.
2020-07-14 14:17:48 +03:00
yenda 67ce4b03aa Revert "upgrade shadow"
This reverts commit 08cbc76111.

Signed-off-by: yenda <eric@status.im>
2020-07-14 13:02:24 +02:00
jakub 84286782f6 bump status-react-jenkins to 1.2.0
This updates a bunch of things in the Jenkins logic.
For details of that see:
https://github.com/status-im/status-react-jenkins/pull/12

It grew out of the changes I made to make PR builds available in Desktop client:
https://github.com/status-im/nim-status-client/pull/507

Changes:
- Bump `status-react-jenkins` library to newer version, probably `1.2.0`
- Update use of `utils.pkgFilename()` in `ci/Jenkinsfile.combined`
- Make all iOS builds go into the same folder: `status-ios`
- Drop e2e build type, infer it from Android ABIs set to `x86` only
- Simplify logic in `nix/mobile/android/release.nix.`

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-07-13 12:13:47 +02:00
Serhy ba0ae149ad Logcat grep, new templates e2e fix
Signed-off-by: Serhy <sergii@status.im>
2020-07-13 12:39:43 +03:00
Churikova Tetiana e366587e8f e2e fix
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-10 17:14:50 +02:00
andrey eef6815616 [#10880] Expanded view with public chat categories 2020-07-10 14:54:39 +02:00
andrey 08cbc76111 upgrade shadow
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-10 12:41:15 +02:00
Churikova Tetiana 2334de58d2 pairing e2e
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
Signed-off-by: Serhy <sergii@status.im>
2020-07-10 10:59:00 +03:00
Serhy 68a07740d8 Update scroll to element
Signed-off-by: Serhy <sergii@status.im>
2020-07-10 10:40:14 +03:00
Roman Volosovskyi bda7386747 [#10784] Fix kk multiacc creation after closing app 2020-07-09 17:32:33 +03:00
Roman Volosovskyi 5101d4d6a5 [keycard] Allow to restore kk multiacc using pairing 2020-07-09 17:30:32 +03:00
Gheorghe Pinzaru 79cf87be86 Ens view list items
Remove extra fn's

Long press animation cancel

Make select primary ens accessible

Add accessibility to controls components

Update e2e tests

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-09 15:15:08 +03:00
Roman Volosovskyi 920bc7d93e [#10195] Separate keystore dir per multiacc
Having all keys related to specific multiacc in a separate dir will
simplify removing of the multiacc. Also it will allow adding of the same
account to different multiaccs.
2020-07-09 13:14:42 +03:00
Serhy e738cd0811 Update ethro key in e2e
Signed-off-by: Serhy <sergii@status.im>
2020-07-08 15:30:58 +03:00
jakub 7d7462356e ci: lower build timeouts to 20 minutes
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-07-08 12:33:33 +02:00
jakub 112132aa94 drop all desktop related files and references
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-07-08 10:26:51 +02:00
Gheorghe Pinzaru bdb4d7fe35 Increase long press move distance
Fix android password visibility change

Do not change secure-text-entry on android password visiblity

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-08 10:07:59 +03:00
Churikova Tetiana 7007b790d5 e2e fix
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-07 14:54:15 +02:00
andrey f2fb1739c0 [#10899] Enable notifications during onboarding 2020-07-07 14:53:56 +02:00
andrey 3800f3f7da [#10891] Add 'Add new contact' and 'Invite friends' button to Contact screen
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-07 14:53:10 +02:00
Serhy 4dda20999b Fix e2e keycard
Signed-off-by: Serhy <sergii@status.im>
2020-07-07 13:15:34 +03:00
jinhojang6 d134136518 Update translations
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
2020-07-06 16:05:47 +02:00
Gheorghe Pinzaru 497af38a7f Update usage for toolbars
Replace all the usage of the button without component

Use quo

Fix tests

List item in multiaccounts

Use list items in contacts

Fix welcome  screen button

Experiment long press

Big list item

Remove old bottom sheet

Use bottom sheet

Keycard

Add error to list item

Stickers panel button

Images panel

Fix z-index in profile

Fix android crash

Fix signing list item

Try fixing test

iOs gas sheet keyboard

Disable root alert in e2e

keycard signing sheet height

Clean up bottom sheet events

Replace flat list in profile

Memorise the manual-close value for bottom sheet

Mailserver QR scanner

Fix e2e tests

E2e fix 2

Fix e2e 3

Remove extra fn

Reduce bridging time for animation

Trick android layout

Try hooks

Fix profile missing ens-name

Disable press on control in list-view

allow disabling animations in list item

Use simple list in wallet assets settings

TBD - this screen should be rewritten from scratch. Now on every interaction the full list is re-rendered, also it makes the wallet main screen to re-render.

Fix send sheet

Handle long press in main thread

UI fixes

perf

Update e2e

fix missing user name in image long press

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-06 13:35:50 +03:00
andrey fad1bd25c0 chill stickers
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-06 12:31:42 +02:00
jakub b95056f3ce ci: fix what version is set for iOS PR builds
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-07-06 09:47:39 +02:00
Roman Volosovskyi 3fe1d6e3eb [keycard] Fix assets message signature 2020-07-03 14:10:37 +03:00
Serhy 16742baecd Update e2e test
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-02 18:59:30 +02:00
andrey 96adbd6185 [#10811] There should be an option to continue opening suspicious urls 2020-07-02 18:59:21 +02:00
andrey 2110446d29 conditional require
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-02 16:23:14 +02:00
andrey 2e7f4212c1 Revert "Remove usage of inline require"
This reverts commit 5f7c7955
2020-07-02 16:23:06 +02:00
Churikova Tetiana 1a6851efa0 uncomment e2e 2020-07-02 16:06:52 +03:00
Roman Volosovskyi 7f1e25a515 [simulated kk] Add proper signing for send/request transaction messages 2020-07-02 16:06:51 +03:00
Serhy ca75a7a057 Use new user instead recovered because message may not be received quick
Signed-off-by: Serhy <sergii@status.im>
2020-07-02 15:54:42 +03:00
andrey 24114f7fe8 [#10105] Add set max to Send transaction
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-02 13:39:48 +02:00
hydr063n 7f4476b253 fix typo in enter the recipient
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-02 11:45:12 +02:00
Gheorghe Pinzaru aa3781e5b5 Onboarding headers style
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-02 11:39:21 +02:00
Churikova Tetiana 6afc313a31 e2e fix2
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-02 11:38:36 +02:00
Churikova Tetiana b008d215e6 e2e fix 2020-07-02 11:38:20 +02:00
andrey 9619a0a204 [#10860] Rename and move Access keys in onboarding 2020-07-02 11:38:20 +02:00
andrey dfb8420353 Disable Register button if not enough SNT for ENS name
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-01 16:25:18 +02:00
jinhojang6 804932e654 Update translations
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-01 14:15:59 +02:00
andrey 49744d89de [#10868] ENS name is pending when tx has failed
Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-01 12:48:08 +02:00
hesterbruikman ac74cf01c5 Log level copy update
Small change to manage #10888

Communicates that restart is required for log change to take effect.

Signed-off-by: andrey <motor4ik@gmail.com>
2020-07-01 12:16:45 +02:00
Gheorghe Pinzaru e290881bf8 Add autoscroll and animation to intro carousel
Add cancelable loop animation

Set index manually

Increase progress bar size

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-07-01 09:32:36 +03:00
jakub b5fda1234e use eth.staging fleet for e2e builds
This should help us acquire more accurate statistics.

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-06-30 10:33:05 +02:00
Gheorghe Pinzaru d916751160 Add PR Scheme for iOs build
Build PR Scheme in PR build

use named parameters, use pr_build boolean

Signed-off-by: Jakub Sokołowski <jakub@status.im>

Enable capabilities

Signed-off-by: Jakub Sokołowski <jakub@status.im>

Add custom app icon

Remove user defined profile

Add PR scheme

Explicit provide provisioning profiles

Fix pr schema

Bump jenkins

Pod bump

Describe pr_build argument

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-06-29 16:16:35 +03:00
jakub c943f5f283 nix: upgrade xcode 11.4.1 to 11.5
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-06-29 10:00:00 +02:00
andrey 056dde0190 [#10870] "Invalid timbre logging level" after upgrade from 1.4 to 1.4.1 or relogin on 1.4.1
Signed-off-by: andrey <motor4ik@gmail.com>
2020-06-29 09:40:55 +02:00
Gheorghe Pinzaru 1733d4dc83 Add control components to Quo
Add new switch component

Add all controls components

Use controls in list items

Delete leftover file

Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-06-26 12:02:02 +03:00
817 changed files with 21323 additions and 28860 deletions
+5 -4
View File
@@ -7,9 +7,7 @@ ETHEREUM_DEV_CLUSTER=1
EXTENSIONS=0
FLEET=eth.prod
GROUP_CHATS_ENABLED=1
HARDWALLET_ENABLED=1
LOG_LEVEL_STATUS_GO=info
LOG_LEVEL=debug
LOG_LEVEL=info
MAILSERVER_CONFIRMATIONS_ENABLED=1
PFS_ENCRYPTION_ENABLED=1
PFS_TOGGLE_VISIBLE=1
@@ -19,8 +17,11 @@ SNOOPY=0
RPC_NETWORKS_ONLY=0
PARTITIONED_TOPIC=0
CONTRACT_NODES=1
MOBILE_UI_FOR_DESKTOP=1
STATUS_GO_PROTOCOL=0
STATUS_GO_ENABLE_NIMBUS=0
KEYCARD_TEST_MENU=0
QR_READ_TEST_MENU=1
ENABLE_ROOT_ALERT=1
ENABLE_REFERRAL_INVITE=1
ENABLE_QUO_PREVIEW=1
APN_TOPIC=im.status.ethereum.pr
+6 -6
View File
@@ -3,11 +3,9 @@ DEFAULT_NETWORK=testnet_rpc
ERC20_CONTRACT_WARNINGS=1
ETHEREUM_DEV_CLUSTER=1
EXTENSIONS=0
FLEET=eth.prod
FLEET=eth.staging
GROUP_CHATS_ENABLED=1
HARDWALLET_ENABLED=1
LOG_LEVEL_STATUS_GO=info
LOG_LEVEL=debug
LOG_LEVEL=info
MAILSERVER_CONFIRMATIONS_ENABLED=0
PAIRING_POPUP_DISABLED=1
PFS_ENCRYPTION_ENABLED=1
@@ -18,9 +16,11 @@ SNOOPY=0
STICKERS_ENABLED=1
PARTITIONED_TOPIC=0
CONTRACT_NODES=1
MOBILE_UI_FOR_DESKTOP=1
BLANK_PREVIEW=0
TOOLTIP_EVENTS=1
COMMANDS_ENABLED=1
KEYCARD_TEST_MENU=1
QR_READ_TEST_MENU=1
QR_READ_TEST_MENU=1
ENABLE_ROOT_ALERT=0
ENABLE_REFERRAL_INVITE=1
APN_TOPIC=im.status.ethereum.pr
+5 -4
View File
@@ -6,9 +6,7 @@ ETHEREUM_DEV_CLUSTER=1
EXTENSIONS=0
FLEET=eth.prod
GROUP_CHATS_ENABLED=1
HARDWALLET_ENABLED=1
LOG_LEVEL_STATUS_GO=info
LOG_LEVEL=debug
LOG_LEVEL=info
MAILSERVER_CONFIRMATIONS_ENABLED=1
MAINNET_WARNING_ENABLED=1
PFS_ENCRYPTION_ENABLED=1
@@ -19,6 +17,9 @@ SNOOPY=0
RPC_NETWORKS_ONLY=0
PARTITIONED_TOPIC=0
CONTRACT_NODES=1
MOBILE_UI_FOR_DESKTOP=1
STATUS_GO_ENABLE_NIMBUS=0
KEYCARD_TEST_MENU=0
ENABLE_ROOT_ALERT=1
ENABLE_REFERRAL_INVITE=1
DISABLE_WALLET_ON_MOBILE_NETWORK=1
APN_TOPIC=im.status.ethereum.pr
+3 -4
View File
@@ -5,8 +5,7 @@ ETHEREUM_DEV_CLUSTER=1
EXTENSIONS=0
FLEET=eth.prod
GROUP_CHATS_ENABLED=1
LOG_LEVEL_STATUS_GO=info
LOG_LEVEL=debug
LOG_LEVEL=info
MAILSERVER_CONFIRMATIONS_ENABLED=1
MAINNET_WARNING_ENABLED=1
PFS_ENCRYPTION_ENABLED=1
@@ -17,5 +16,5 @@ SNOOPY=0
RPC_NETWORKS_ONLY=0
PARTITIONED_TOPIC=0
CONTRACT_NODES=1
MOBILE_UI_FOR_DESKTOP=1
HARDWALLET_ENABLED=1
ENABLE_ROOT_ALERT=1
ENABLE_REFERRAL_INVITE=1
+3 -4
View File
@@ -5,8 +5,7 @@ ETHEREUM_DEV_CLUSTER=0
EXTENSIONS=0
FLEET=eth.prod
GROUP_CHATS_ENABLED=1
LOG_LEVEL_STATUS_GO=
LOG_LEVEL=info
LOG_LEVEL=
MAILSERVER_CONFIRMATIONS_ENABLED=1
MAINNET_WARNING_ENABLED=1
PFS_ENCRYPTION_ENABLED=1
@@ -16,5 +15,5 @@ POW_TIME=1
SNOOPY=0
RPC_NETWORKS_ONLY=1
PARTITIONED_TOPIC=0
MOBILE_UI_FOR_DESKTOP=1
HARDWALLET_ENABLED=1
ENABLE_ROOT_ALERT=1
ENABLE_REFERRAL_INVITE=0
+2 -30
View File
@@ -25,7 +25,6 @@ DerivedData
*.ipa
*.xcuserstate
project.xcworkspace
xcshareddata
# Android/IJ
#
@@ -68,9 +67,6 @@ env/dev/env/config.cljs
externs/
shim.js
# Desktop build
index.desktop.js
# Generated by lein voom
#
/pom.xml
@@ -104,6 +100,7 @@ Statusgo.framework
/ios/Pods/
/ios/StatusIm.xcworkspace
/ios/react-native-xcode.log
/ios/set_xcode_version.log
.ruby-version
status-e2e/
@@ -128,12 +125,8 @@ fastlane/README.md
# emacs
.dir-locals.el
#ignore platform-specific files in the root since they are only symlinks to files in folders 'desktop/js_files' and 'mobile/js_files'
/DEPENDENCIES.md
# We don't use NPM
/package-lock.json
/package.json
/metro.config.js
/yarn.lock
/.re-natal
/re-natal
@@ -141,27 +134,6 @@ fastlane/README.md
pkg
/BUILD_NUMBER
# Status Desktop
cmake_install.cmake
CMakeCache.txt
**/CMakeFiles/
/StatusImPackage/*
*.AppImage
Status-Windows-x86_64.exe
/desktop/bin/*
/desktop/lib/*
/desktop/modules/*
/desktop/Makefile
/desktop/graph_info.json
/desktop/run-app.bat
/desktop/run-app.sh
/desktop/CMakeFiles/
/desktop/reportApp/Makefile
/deployment/windows/Status.rc
*_autogen/
CompleteBundleWin.cmake
logger_settings.ini
# Conan
conan*.txt
conanbuildinfo.*
@@ -122,10 +122,6 @@ used to get user language and interact with i18n.js
used to send email to support when phone is shaked
## "react-native-navigation-twopane": "git+https://github.com/status-im/react-native-navigation-twopane.git#v0.0.2-status"
used by desktop
## "react-native-screens": "1.0.0-alpha.22"
used by react-navigation
+2 -34
View File
@@ -1,4 +1,4 @@
.PHONY: nix-add-gcroots clean nix-clean run-metro react-native-desktop test release _list _fix-node-perms _tmpdir-mk _tmpdir-rm
.PHONY: nix-add-gcroots clean nix-clean run-metro test release _list _fix-node-perms _tmpdir-mk _tmpdir-rm
help: SHELL := /bin/sh
help: ##@other Show this help
@@ -159,6 +159,7 @@ release-android: export BUILD_ENV ?= prod
release-android: export BUILD_TYPE ?= nightly
release-android: export BUILD_NUMBER ?= $(TMP_BUILD_NUMBER)
release-android: export KEYSTORE_PATH ?= $(HOME)/.gradle/status-im.keystore
release-android: export ANDROID_APK_SIGNED ?= true
release-android: export ANDROID_ABI_SPLIT ?= false
release-android: export ANDROID_ABI_INCLUDE ?= armeabi-v7a;arm64-v8a;x86
release-android: keystore ##@build build release for Android
@@ -171,18 +172,6 @@ release-ios: watchman-clean ##@build build release for iOS release
$(MAKE) jsbundle-ios && \
xcodebuild -workspace ios/StatusIm.xcworkspace -scheme StatusIm -configuration Release -destination 'generic/platform=iOS' -UseModernBuildSystem=N clean archive
release-desktop: export TARGET ?= $(HOST_OS)
release-desktop: ##@build build release for desktop release based on TARGET
@$(MAKE) jsbundle-desktop && \
scripts/build-desktop.sh; \
$(MAKE) watchman-clean
release-windows-desktop: export TARGET ?= windows
release-windows-desktop: ##@build build release for windows desktop release
@$(MAKE) jsbundle-desktop && \
scripts/build-desktop.sh; \
$(MAKE) watchman-clean
jsbundle-android: SHELL := /bin/sh
jsbundle-android: export TARGET := android
jsbundle-android: export BUILD_ENV ?= prod
@@ -208,10 +197,6 @@ status-go-ios: SHELL := /bin/sh
status-go-ios: ##@status-go Compile status-go for iOS app
nix/scripts/build.sh targets.status-go.mobile.ios
status-go-desktop: SHELL := /bin/sh
status-go-desktop: ##@status-go Compile status-go for desktop app
nix/scripts/build.sh targets.status-go.desktop
#--------------
# Watch, Build & Review changes
#--------------
@@ -220,10 +205,6 @@ run-clojure: export TARGET := clojure
run-clojure: ##@run Watch for and build Clojure changes for mobile
yarn shadow-cljs watch mobile
run-clojure-desktop: export TARGET ?= $(HOST_OS)
run-clojure-desktop: #@run Watch for and build Clojure changes for desktop
clj -R:dev build.clj watch --platform desktop
run-metro: export TARGET := clojure
run-metro: ##@run Start Metro to build React Native changes
@scripts/start-react-native.sh
@@ -246,10 +227,6 @@ else
npx react-native run-ios
endif
run-desktop: export TARGET ?= $(HOST_OS)
run-desktop: ##@run Run Desktop build
npx react-native run-desktop
#--------------
# Tests
#--------------
@@ -280,15 +257,6 @@ coverage: ##@test Run tests once in NodeJS generating coverage
# Other
#--------------
start-desktop-server: export TARGET ?= $(HOST_OS)
start-desktop-server: #@other Start ubuntu-server.js for desktop
node ubuntu-server.js
react-native-desktop: export TARGET ?= $(HOST_OS)
react-native-desktop: export _NIX_PURE ?= true
react-native-desktop: ##@other Start react native packager
@scripts/start-react-native.sh
geth-connect: export TARGET := android-env
geth-connect: ##@other Connect to Geth on the device
adb forward tcp:8545 tcp:8545 && \
-2
View File
@@ -67,8 +67,6 @@ info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this
Update yarn.lock file. In order to do this, perform the following steps on a clean `status-react` repo:
```
cd status-react
ln -sf mobile/js_files/package.json .
ln -sf mobile/js_files/yarn.lock .
yarn install
```
and don't forget to commit updated `yarn.lock` together with `package.json`.
+1 -1
View File
@@ -1 +1 @@
1.4.1
1.7.2
+5 -3
View File
@@ -228,6 +228,8 @@ android {
keyAlias 'androiddebugkey'
keyPassword 'android'
}
/* Caution! In production, you need to generate your own keystore file.
* See: https://facebook.github.io/react-native/docs/signed-apk-android */
release {
/* environment variables take precedence over gradle.properties file */
storeFile file(getEnvOrConfig('KEYSTORE_PATH').replaceAll("~", System.properties['user.home']))
@@ -253,11 +255,11 @@ android {
resValue "string", "build_config_package", "im.status.ethereum"
}
release {
// Caution! In production, you need to generate your own keystore file.
// see https://facebook.github.io/react-native/docs/signed-apk-android.
minifyEnabled enableProguardInReleaseBuilds
proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
signingConfig signingConfigs.release
if (getEnvOrConfig('ANDROID_APK_SIGNED').toBoolean()) {
signingConfig signingConfigs.release
}
}
pr {
initWith release
+2
View File
@@ -21,6 +21,8 @@
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.USE_FINGERPRINT" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />
<uses-permission android:name="com.android.vending.BILLING" />
<!-- these permissions should be removed -->
@@ -199,7 +199,7 @@ public class MainActivity extends ReactFragmentActivity
private static final Integer FREQUENCY_OF_REMINDER_IN_PERCENT = 5;
private boolean shouldShowRootedNotification() {
if (RootUtil.isDeviceRooted()) {
if (RootUtil.isDeviceRooted() && BuildConfig.ENABLE_ROOT_ALERT == "1") {
if (userRejectedRootedNotification()) {
return ((Math.random() * 100) < FREQUENCY_OF_REMINDER_IN_PERCENT);
} else return true;
+3 -1
View File
@@ -42,10 +42,12 @@ KEYSTORE_KEY_PASSWORD=password
ANDROID_ABI_SPLIT=false
# Some platforms are excluded though
ANDROID_ABI_INCLUDE=armeabi-v7a;arm64-v8a;x86
# F-Droid builds need to be unsigned
ANDROID_APK_SIGNED=true
org.gradle.jvmargs=-Xmx8704M
versionCode=9999
# Flipper
FLIPPER_VERSION=0.35.0
FLIPPER_VERSION=0.35.0
+7 -8
View File
@@ -1,4 +1,4 @@
library 'status-react-jenkins@v1.1.7'
library 'status-react-jenkins@v1.2.5'
pipeline {
agent { label 'linux' }
@@ -6,7 +6,7 @@ pipeline {
options {
timestamps()
/* Prevent Jenkins jobs from running forever */
timeout(time: 45, unit: 'MINUTES')
timeout(time: 20, unit: 'MINUTES')
/* Limit builds retained */
buildDiscarder(logRotator(
numToKeepStr: '10',
@@ -101,12 +101,11 @@ pipeline {
} else { /* if no universal is available pick first */
env.PKG_URL = urls.first()
}
/* build type specific */
switch (btype) {
case 'nightly':
env.DIAWI_URL = android.uploadToDiawi(); break;
case 'e2e':
env.SAUCE_URL = android.uploadToSauceLabs(); break;
if (utils.isNightlyBuild()) {
env.DIAWI_URL = android.uploadToDiawi()
}
if (utils.isE2EBuild()) {
env.SAUCE_URL = android.uploadToSauceLabs()
}
}
}
+5 -4
View File
@@ -1,4 +1,4 @@
library 'status-react-jenkins@v1.1.7'
library 'status-react-jenkins@v1.2.5'
pipeline {
agent { label 'linux' }
@@ -7,7 +7,7 @@ pipeline {
timestamps()
disableConcurrentBuilds()
/* Prevent Jenkins jobs from running forever */
timeout(time: 45, unit: 'MINUTES')
timeout(time: 40, unit: 'MINUTES')
/* Limit builds retained */
buildDiscarder(logRotator(
numToKeepStr: '10',
@@ -44,9 +44,10 @@ pipeline {
//jenkins.copyArts(iose2e)
jenkins.copyArts(apk)
jenkins.copyArts(apke2e)
sha = "pkg/${utils.pkgFilename('sha256')}"
dir('pkg') {
/* generate sha256 checksums for upload */
sh "sha256sum * | tee ${utils.pkgFilename(btype, 'sha256')}"
sh "sha256sum * | tee ../${sha}"
archiveArtifacts('*')
}
} }
@@ -60,7 +61,7 @@ pipeline {
iOS: utils.pkgUrl(ios), /*iOSe2e: utils.pkgUrl(iose2e),*/
Diawi: utils.utils.getEnv(ios, 'DIAWI_URL'),
/* upload the sha256 checksums file too */
SHA: s3.uploadArtifact(utils.pkgFind('sha256')),
SHA: s3.uploadArtifact(sha),
]
/* add URLs to the build description */
jenkins.setBuildDesc(urls)
+3 -3
View File
@@ -1,7 +1,7 @@
library 'status-react-jenkins@v1.1.7'
library 'status-react-jenkins@v1.2.5'
pipeline {
agent { label 'macos-xcode-11.4.1' }
agent { label 'macos-xcode-11.5' }
parameters {
string(
@@ -14,7 +14,7 @@ pipeline {
options {
timestamps()
/* Prevent Jenkins jobs from running forever */
timeout(time: 45, unit: 'MINUTES')
timeout(time: 25, unit: 'MINUTES')
/* Limit builds retained */
buildDiscarder(logRotator(
numToKeepStr: '10',
-125
View File
@@ -1,125 +0,0 @@
library 'status-react-jenkins@v1.1.7'
pipeline {
agent { label 'linux' }
parameters {
string(
name: 'BUILD_TYPE',
description: 'Specify build type. Values: pr / nightly / release',
defaultValue: 'pr',
)
}
options {
timestamps()
/* Prevent Jenkins jobs from running forever */
timeout(time: 40, unit: 'MINUTES')
/* Limit builds retained */
buildDiscarder(logRotator(
numToKeepStr: '10',
daysToKeepStr: '20',
artifactNumToKeepStr: '10',
))
/* Allows combined build to copy */
copyArtifactPermission('/status-react/*')
}
/**
* WARNING: Jenkins ignores PATH changes in Docker
* https://issues.jenkins-ci.org/browse/JENKINS-49076
**/
environment {
LANG = "en_US.UTF-8"
LC_ALL = "en_US.UTF-8"
LANGUAGE = "en_US.UTF-8"
TARGET = 'linux'
NIX_CONF_DIR = "${env.WORKSPACE}/nix"
VERBOSE_LEVEL = '3'
/* We use EXECUTOR_NUMBER to avoid multiple instances clashing */
YARN_CACHE_FOLDER = "/var/tmp/yarn-${EXECUTOR_NUMBER}"
GRADLE_USER_HOME = "/var/tmp/gradle-${EXECUTOR_NUMBER}"
}
stages {
stage('Prep') {
steps {
script {
btype = utils.getBuildType()
print "Running ${btype} build!"
jenkins.abortPreviousRunningBuilds()
/* Cleanup and Prep */
commonPrep(btype)
}
}
}
stage('Parallel Assemble') {
parallel {
stage('Checks') { stages {
stage('Lint') {
steps {
script {
/* We want the build result to be uploaded */
catchError(
message: 'Linting check failed!',
buildResult: 'FAILURE',
stageResult: 'FAILURE'
) {
sh 'make lint'
}
}
}
}
stage('Tests') {
steps {
script {
sh 'make test'
}
}
}
} }
stage('Build') { stages {
stage('JSBundle') {
steps {
script { desktop.buildJSBundle() }
}
}
stage('Compile') {
steps {
script { desktop.compile() }
}
}
stage('Bundle') {
steps {
script { app = desktop.bundleLinux(btype) }
}
}
} }
}
}
stage('Parallel Upload') {
parallel {
stage('Archive') {
steps {
archiveArtifacts app
}
}
stage('Upload') {
steps {
script { env.PKG_URL = s3.uploadArtifact(app) }
}
}
}
}
stage('Cleanup') {
steps {
sh 'make watchman-clean'
sh 'make clean'
}
}
}
post {
success { script { github.notifyPR(true) } }
failure { script { github.notifyPR(false) } }
}
}
-123
View File
@@ -1,123 +0,0 @@
library 'status-react-jenkins@v1.1.7'
pipeline {
agent { label 'macos-xcode-11.4.1' }
parameters {
string(
name: 'BUILD_TYPE',
description: 'Specify build type. Values: pr / nightly / release',
defaultValue: 'pr',
)
}
options {
timestamps()
/* Prevent Jenkins jobs from running forever */
timeout(time: 30, unit: 'MINUTES')
/* Limit builds retained */
buildDiscarder(logRotator(
numToKeepStr: '10',
daysToKeepStr: '20',
artifactNumToKeepStr: '10',
))
/* Allows combined build to copy */
copyArtifactPermission('/status-react/*')
}
environment {
LANG = "en_US.UTF-8"
LC_ALL = "en_US.UTF-8"
LANGUAGE = "en_US.UTF-8"
TARGET = 'macos'
NIX_CONF_DIR = "${env.WORKSPACE}/nix"
/* See nix/README.md */
NIX_IGNORE_SYMLINK_STORE = 1
VERBOSE_LEVEL = '3'
/* We use EXECUTOR_NUMBER to avoid multiple instances clashing */
YARN_CACHE_FOLDER = "/var/tmp/yarn-${EXECUTOR_NUMBER}"
GRADLE_USER_HOME = "/var/tmp/gradle-${EXECUTOR_NUMBER}"
}
stages {
stage('Prep') {
steps {
script {
btype = utils.getBuildType()
print "Running ${btype} build!"
jenkins.abortPreviousRunningBuilds()
/* Cleanup and Prep */
commonPrep(btype)
}
}
}
stage('Parallel Assemble') {
parallel {
stage('Checks') { stages {
stage('Lint') {
steps {
script {
/* We want the build result to be uploaded */
catchError(
message: 'Linting check failed!',
buildResult: 'FAILURE',
stageResult: 'FAILURE'
) {
sh 'make lint'
}
}
}
}
stage('Tests') {
steps {
script {
sh 'make test'
}
}
}
} }
stage('Build') { stages {
stage('JSBundle') {
steps {
script { desktop.buildJSBundle() }
}
}
stage('Compile') {
steps {
script { desktop.compile() }
}
}
stage('Bundle') {
steps {
script { dmg = desktop.bundleMacOS(btype) }
}
}
} }
}
}
stage('Parallel Upload') {
parallel {
stage('Archive') {
steps {
archiveArtifacts dmg
}
}
stage('Upload') {
steps {
script { env.PKG_URL = s3.uploadArtifact(dmg) }
}
}
}
}
stage('Cleanup') {
steps {
sh 'make watchman-clean'
sh 'make clean'
}
}
}
post {
success { script { github.notifyPR(true) } }
failure { script { github.notifyPR(false) } }
}
}
+2 -2
View File
@@ -1,4 +1,4 @@
library 'status-react-jenkins@v1.1.7'
library 'status-react-jenkins@v1.2.5'
pipeline {
agent { label params.AGENT_LABEL }
@@ -36,7 +36,7 @@ pipeline {
}
stage('Build status-go') {
steps { script {
def platforms = ['mobile.android', 'mobile.ios', 'desktop']
def platforms = ['mobile.android', 'mobile.ios']
if (uname != "Darwin") {
platforms.removeAll { it == "ios" }
}
-128
View File
@@ -1,128 +0,0 @@
library 'status-react-jenkins@v1.1.7'
pipeline {
agent { label 'linux' }
parameters {
string(
name: 'BUILD_TYPE',
description: 'Specify build type. Values: pr / nightly / release',
defaultValue: 'pr',
)
}
options {
timestamps()
/* Prevent Jenkins jobs from running forever */
timeout(time: 45, unit: 'MINUTES')
/* Limit builds retained */
buildDiscarder(logRotator(
numToKeepStr: '10',
daysToKeepStr: '20',
artifactNumToKeepStr: '10',
))
/* Allows combined build to copy */
copyArtifactPermission('/status-react/*')
}
/**
* WARNING: Jenkins ignores PATH changes in Docker
* https://issues.jenkins-ci.org/browse/JENKINS-49076
**/
environment {
LANG = "en_US.UTF-8"
LC_ALL = "en_US.UTF-8"
LANGUAGE = "en_US.UTF-8"
TARGET = 'windows'
NIX_CONF_DIR = "${env.WORKSPACE}/nix"
VERBOSE_LEVEL = '3'
/* Conan settings */
CONAN_PRINT_RUN_COMMANDS = '1'
CONAN_SYSREQUIRES_MODE = 'disabled'
CONAN_SYSREQUIRES_SUDO = '0'
/* We use EXECUTOR_NUMBER to avoid multiple instances clashing */
YARN_CACHE_FOLDER = "/var/tmp/yarn-${EXECUTOR_NUMBER}"
}
stages {
stage('Prep') {
steps {
script {
btype = utils.getBuildType()
print "Running ${btype} build!"
jenkins.abortPreviousRunningBuilds()
/* Cleanup and Prep */
commonPrep(btype)
}
}
}
stage('Parallel Assemble') {
parallel {
stage('Checks') { stages {
stage('Lint') {
steps {
script {
/* We want the build result to be uploaded */
catchError(
message: 'Linting check failed!',
buildResult: 'FAILURE',
stageResult: 'FAILURE'
) {
sh 'make lint'
}
}
}
}
stage('Tests') {
steps {
script {
sh 'make test'
}
}
}
} }
stage('Build') { stages {
stage('JSBundle') {
steps {
script { desktop.buildJSBundle() }
}
}
stage('Compile') {
steps {
script { desktop.compile() }
}
}
stage('Bundle') {
steps {
script { app = desktop.bundleWindows(btype) }
}
}
} }
}
}
stage('Parallel Upload') {
parallel {
stage('Archive') {
steps {
archiveArtifacts app
}
}
stage('Upload') {
steps {
script { env.PKG_URL = s3.uploadArtifact(app) }
}
}
}
}
stage('Cleanup') {
steps {
sh 'make watchman-clean'
sh 'make clean'
}
}
}
post {
success { script { github.notifyPR(true) } }
failure { script { github.notifyPR(false) } }
}
}
+1 -1
View File
@@ -1,4 +1,4 @@
library 'status-react-jenkins@v1.1.7'
library 'status-react-jenkins@v1.2.5'
pipeline {
agent { label 'macos' }
+1 -1
View File
@@ -1,4 +1,4 @@
library 'status-react-jenkins@v1.1.7'
library 'status-react-jenkins@v1.2.5'
pipeline {
agent { label 'linux' }
View File
View File
@@ -1,7 +0,0 @@
[Desktop Entry]
Type=Application
Name=Status
Comment=Status Desktop
Exec=Status
Icon=Status
Categories=Network;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 86 KiB

-43
View File
@@ -1,43 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDisplayName</key>
<string>Status</string>
<key>CFBundleExecutable</key>
<string>Status</string>
<key>CFBundleIconFile</key>
<string>status-icon</string>
<key>CFBundleIdentifier</key>
<string>im.status.statusim</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>Status</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>0.1</string>
<key>CFBundleVersion</key>
<string>0.1</string>
<key>LSMinimumSystemVersion</key>
<string>10.9.0</string>
<key>NSHighResolutionCapable</key>
<string>True</string>
<key>NSPrincipalClass</key>
<string>NSApplication</string>
<key>CFBundleURLTypes</key>
<array>
<dict>
<key>CFBundleURLSchemes</key>
<array>
<string>status-im</string>
</array>
<key>CFBundleURLName</key>
<string>im.status.ethereum.applink-desktop</string>
</dict>
</array>
</dict>
</plist>
-19
View File
@@ -1,19 +0,0 @@
#!/usr/bin/env bash
function make_icns {
local file="../status-icon.png"
local iconset="$(mktemp -d)"
local output_icon="status-icon.icns"
for size in {16,32,64,128,256,512}; do
sips --resampleHeightWidth "${size}" "${size}" "${file}" --out "${iconset}/icon_${size}x${size}.png" &> /dev/null
sips --resampleHeightWidth "$((size * 2))" "$((size * 2))" "${file}" --out "${iconset}/icon_${size}x${size}@2x.png" &> /dev/null
done
mv "${iconset}" "${iconset}.iconset"
iconutil --convert icns "${iconset}.iconset" --output "${output_icon}"
echo "${output_icon}" # so its path is returned when the function ends
}
make_icns
Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.
-4
View File
@@ -1,4 +0,0 @@
[Paths]
Plugins = ../PlugIns
Imports = ../Resources/qml
Qml2Imports = ../Resources/qml
-18
View File
@@ -1,18 +0,0 @@
{
"title": "Status",
"background": "dmg-background.png",
"contents": [
{
"x": 385,
"y": 235,
"type": "link",
"path": "/Applications"
},
{
"x": 170,
"y": 236,
"type": "file",
"path": "../../StatusImPackage/Status.app"
}
]
}
Binary file not shown.
Binary file not shown.

Before

Width:  |  Height:  |  Size: 121 KiB

-24
View File
@@ -1,24 +0,0 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="68" height="68" viewBox="0 0 68 68">
<defs>
<ellipse id="b" cx="31.969" cy="31.938" rx="31.969" ry="31.938"/>
<filter id="a" width="114.1%" height="114.1%" x="-7%" y="-3.9%" filterUnits="objectBoundingBox">
<feOffset dy="1" in="SourceAlpha" result="shadowOffsetOuter1"/>
<feGaussianBlur in="shadowOffsetOuter1" result="shadowBlurOuter1" stdDeviation=".5"/>
<feColorMatrix in="shadowBlurOuter1" result="shadowMatrixOuter1" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.22 0"/>
<feOffset dy="1" in="SourceAlpha" result="shadowOffsetOuter2"/>
<feGaussianBlur in="shadowOffsetOuter2" result="shadowBlurOuter2" stdDeviation="1"/>
<feColorMatrix in="shadowBlurOuter2" result="shadowMatrixOuter2" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.25 0"/>
<feMerge>
<feMergeNode in="shadowMatrixOuter1"/>
<feMergeNode in="shadowMatrixOuter2"/>
</feMerge>
</filter>
</defs>
<g fill="none" fill-rule="nonzero">
<g transform="translate(2 1)">
<use fill="#000" filter="url(#a)" xlink:href="#b"/>
<use fill="#FFF" xlink:href="#b"/>
</g>
<path fill="#4360DF" d="M34 1.062c-17.673 0-32 14.313-32 31.97C2 50.686 16.327 65 34 65c17.673 0 32-14.313 32-31.969 0-8.478-3.371-16.61-9.373-22.605A32.016 32.016 0 0 0 34 1.062zm-4.902 46.17c-4.013.225-8.023-2.192-8.243-6.118-.213-3.859 2.799-6.44 7.779-6.72 3.674-.207 5.97.628 9.65.421.911-.05 1.817-.18 2.706-.386-.543 6.633-5.352 12.435-11.892 12.803zm10.298-14.497c-3.834.222-6.238-.671-10.076-.45-.951.053-1.896.191-2.823.413.56-7.084 5.587-13.288 12.414-13.68 4.189-.243 8.376 2.342 8.604 6.536.224 4.124-2.922 6.883-8.119 7.18z"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 1.8 KiB

-71
View File
@@ -1,71 +0,0 @@
#include "resource.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE resource.
//
#ifndef APSTUDIO_INVOKED
#include "targetver.h"
#endif
#define APSTUDIO_HIDDEN_SYMBOLS
#include "windows.h"
#undef APSTUDIO_HIDDEN_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
LANGUAGE 9, 1
/////////////////////////////////////////////////////////////////////////////
//
// Icon
//
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
IDI_STATUS ICON "${ICO_RESOURCE_PATH}"
#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//
1 TEXTINCLUDE
BEGIN
"resource.h\0"
END
2 TEXTINCLUDE
BEGIN
"#ifndef APSTUDIO_INVOKED\r\n"
"#include ""targetver.h""\r\n"
"#endif\r\n"
"#define APSTUDIO_HIDDEN_SYMBOLS\r\n"
"#include ""windows.h""\r\n"
"#undef APSTUDIO_HIDDEN_SYMBOLS\r\n"
"\0"
END
3 TEXTINCLUDE
BEGIN
"\r\n"
"\0"
END
#endif // APSTUDIO_INVOKED
#endif
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE resource.
//
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED
@@ -1,23 +0,0 @@
!include LogicLib.nsh
!include WordFunc.nsh
Function SnoreWinVer
ReadRegStr $R0 HKLM "SOFTWARE\Microsoft\Windows NT\CurrentVersion" CurrentVersion
${VersionCompare} "6.2" $R0 $R0
${If} $R0 == 1
Push "NotWin8"
${Else}
Push "AtLeastWin8"
${EndIf}
FunctionEnd
!macro SnoreShortcut path exe appID
Call SnoreWinVer
Pop $0
${If} $0 == "AtLeastWin8"
nsExec::ExecToLog '"${SnoreToastExe}" -install "${path}" "${exe}" "${appID}"'
${Else}
DetailPrint "Creating shortcut to ${exe}"
CreateShortCut "${path}" "${exe}"
${EndIf}
!macroend
-299
View File
@@ -1,299 +0,0 @@
/*** UAC Plug-in ***
Interactive User (MediumIL) Admin user (HighIL)
***[Setup.exe]************* ***[Setup.exe]**************
* * * *
* +++[.OnInit]+++++++++++ * * +++[.OnInit]++++++++++++ *
* + UAC_RunElevated >---+-+----> * + + *
* + NSIS.Quit + * * + + *
* +++++++++++++++++++++++ * * ++++++++++++++++++++++++ *
* * * *
* * * *
* +++[Section]+++++++++++ * * +++[Section]++++++++++++ *
* + + * /--+-+-<UAC_AsUser_ExecShell+ *
* +++++++++++++++++++++++ * | * ++++++++++++++++++++++++ *
* * | * *
* Win32.ShellExecute <---+--/ * *
* * * *
*************************** ****************************
*/
!ifndef UAC_HDR__INC
!verbose push
!verbose 3
!ifndef UAC_VERBOSE
!define UAC_VERBOSE 3
!endif
!verbose ${UAC_VERBOSE}
!define UAC_HDR__INC 0x00020400 ;MMmmbbrr
!include LogicLib.nsh
/* UAC_RunElevated
**
** Starts the elevation operation.
**
** Return values:
**
** $0: Win32 error code (0 on success, 1223 if user aborted elevation dialog, anything else should be treated as a fatal error)
** $1: If $0==0:
** 0 UAC is not supported by the OS
** 1 Started a elevated child process, the current process should act like a wrapper (Call Quit without any further processing)
** 2 The process is already running @ HighIL (Member of admin group)
** 3 You should call RunElevated again (This can happen if a user without admin priv. is used in the runas dialog)
** $2: If $0==0 && $1==1: ExitCode of the elevated fork process (The NSIS errlvl is also set)
** $3: If $0==0: 1 if the user is a member of the admin group or 0 otherwise
**/
!macro UAC_RunElevated
UAC::_ 0
!macroend
!macro UAC_PageElevation_RunElevated
UAC::_ 0
!macroend
/*!macro UAC_OnInitElevation_RunElevated
UAC::_ 0
!macroend
!macro UAC_OnInitElevation_OnGuiInit
!macroend*/
/* UAC_GetIntegrityLevel <NSISVar:Output | "s">
**
** Get integrity level of current process
**
**/
!macro UAC_GetIntegrityLevel outvar
UAC::_ 6
!if "${outvar}" != "s"
Pop ${outvar}
!endif
!macroend
/* UAC_IsAdmin
**
** Is the current process running with administrator privileges? Result in $0
**
** ${If} ${UAC_IsAdmin} ...
**
**/
!macro UAC_IsAdmin
UAC::_ 2
!macroend
!define UAC_IsAdmin `"" UAC_IsAdmin ""`
!macro _UAC_IsAdmin _a _b _t _f
!insertmacro _UAC_MakeLL_Cmp _!= 0 2s
!macroend
/* UAC_IsInnerInstance
**
** Does the current process have a NSIS/UAC parent process that is part of the elevation operation?
**
** ${If} ${UAC_IsInnerInstance} ...
**
**/
!macro UAC_IsInnerInstance
UAC::_ 3
!macroend
!define UAC_IsInnerInstance `"" UAC_IsInnerInstance ""`
!macro _UAC_IsInnerInstance _a _b _t _f
!insertmacro _UAC_MakeLL_Cmp _!= 0 3s
!macroend
/* UAC_PageElevation_OnInit, UAC_PageElevation_OnGuiInit,
**
** Helper macros for elevation on a custom elevation page, see the DualMode example for more information.
**
**/
!macro UAC_Notify_OnGuiInit
UAC::_ 4
!macroend
!macro UAC_PageElevation_OnGuiInit
!insertmacro UAC_Notify_OnGuiInit
!macroend
!macro UAC_PageElevation_OnInit
UAC::_ 5
${IfThen} ${Errors} ${|} Quit ${|}
!macroend
/* UAC_AsUser_Call <Function|Label> <NSISAddressName> <UAC_* flags>
**
** Calls a function or label in the user process instance.
** All the UAC_AsUser_* macros use this helper macro.
**
**/
!define UAC_SYNCREGISTERS 0x1
;define UAC_SYNCSTACK 0x2
!define UAC_SYNCOUTDIR 0x4
!define UAC_SYNCINSTDIR 0x8
;define UAC_CLEARERRFLAG 0x10
!macro UAC_AsUser_Call type name flags
push $0
Get${type}Address $0 ${name}
!verbose push
!verbose ${UAC_VERBOSE}
!insertmacro _UAC_ParseDefineFlagsToInt _UAC_AsUser_Call__flags ${flags}
!verbose pop
StrCpy $0 "1$0:${_UAC_AsUser_Call__flags}"
!undef _UAC_AsUser_Call__flags
Exch $0
UAC::_
!macroend
/*
** UAC_AsUser_GetSection <Flags|InstTypes|Size|Text> <SectionIndex> <NSISVar:Output>
*/
!macro UAC_AsUser_GetSection secprop secidx outvar
!insertmacro _UAC_AsUser_GenOp ${outvar} SectionGet${secprop} ${secidx} ""
!macroend
/*
** UAC_AsUser_GetGlobalVar <NSISVar:SourceAndOutput>
** UAC_AsUser_GetGlobal <NSISVar:Output> <NSISVar:Source>
*/
!macro UAC_AsUser_GetGlobalVar var
!insertmacro _UAC_AsUser_GenOp ${var} StrCpy "" ${var}
!macroend
!macro UAC_AsUser_GetGlobal outvar srcvar
!insertmacro _UAC_AsUser_GenOp ${outvar} StrCpy "" ${srcvar}
!macroend
/*
** UAC_AsUser_ExecShell <Verb> <ApplicationOrFile> <Parameters> <Working Directory> <SW_*>
**
** Call ExecShell in the user process instance.
**
*/
!macro UAC_AsUser_ExecShell verb command params workdir show
!insertmacro _UAC_IncL
goto _UAC_L_E_${__UAC_L}
_UAC_L_F_${__UAC_L}:
ExecShell "${verb}" "${command}" '${params}' ${show}
return
_UAC_L_E_${__UAC_L}:
!if "${workdir}" != ""
push $outdir
SetOutPath "${workdir}"
!endif
!insertmacro UAC_AsUser_Call Label _UAC_L_F_${__UAC_L} ${UAC_SYNCREGISTERS}|${UAC_SYNCOUTDIR}|${UAC_SYNCINSTDIR} #|${UAC_CLEARERRFLAG}
!if "${workdir}" != ""
pop $outdir
SetOutPath $outdir
!endif
!macroend
!macro _UAC_MakeLL_Cmp cmpop cmp pluginparams
!insertmacro _LOGICLIB_TEMP
UAC::_ ${pluginparams}
pop $_LOGICLIB_TEMP
!insertmacro ${cmpop} $_LOGICLIB_TEMP ${cmp} `${_t}` `${_f}`
!macroend
!macro _UAC_definemath def val1 op val2
!define /math _UAC_definemath "${val1}" ${op} ${val2}
!ifdef ${def}
!undef ${def}
!endif
!define ${def} "${_UAC_definemath}"
!undef _UAC_definemath
!macroend
!macro _UAC_ParseDefineFlags_orin parse outflags
!searchparse /noerrors ${${parse}} "" _UAC_ParseDefineFlags_orin_f1 "|" _UAC_ParseDefineFlags_orin_f2
!define _UAC_ParseDefineFlags_orin_this ${_UAC_ParseDefineFlags_orin_f1}
!undef ${parse}
!define ${parse} ${_UAC_ParseDefineFlags_orin_f2}
!define _UAC_ParseDefineFlags_orin_saveout ${${outflags}}
!undef ${outflags}
!define /math ${outflags} "${_UAC_ParseDefineFlags_orin_saveout}" | "${_UAC_ParseDefineFlags_orin_this}"
!undef _UAC_ParseDefineFlags_orin_saveout
!undef _UAC_ParseDefineFlags_orin_this
!ifdef _UAC_ParseDefineFlags_orin_f1
!undef _UAC_ParseDefineFlags_orin_f1
!endif
!ifdef _UAC_ParseDefineFlags_orin_f2
!undef _UAC_ParseDefineFlags_orin_f2
!endif
!macroend
!macro _UAC_ParseDefineFlags_Begin _outdef _in
!define _UAC_PDF${_outdef}_parse "${_in}"
!define _UAC_PDF${_outdef}_flags ""
!define _UAC_PDF${_outdef}_r 0
!insertmacro _UAC_ParseDefineFlags_orin _UAC_PDF${_outdef}_parse _UAC_PDF${_outdef}_flags ;0x1
!insertmacro _UAC_ParseDefineFlags_orin _UAC_PDF${_outdef}_parse _UAC_PDF${_outdef}_flags ;0x2
!insertmacro _UAC_ParseDefineFlags_orin _UAC_PDF${_outdef}_parse _UAC_PDF${_outdef}_flags ;0x4
!insertmacro _UAC_ParseDefineFlags_orin _UAC_PDF${_outdef}_parse _UAC_PDF${_outdef}_flags ;0x8
!insertmacro _UAC_ParseDefineFlags_orin _UAC_PDF${_outdef}_parse _UAC_PDF${_outdef}_flags ;0x10
!macroend
!macro _UAC_ParseDefineFlags_End _outdef
!define ${_outdef} ${_UAC_PDF${_outdef}_r}
!undef _UAC_PDF${_outdef}_r
!undef _UAC_PDF${_outdef}_flags
!undef _UAC_PDF${_outdef}_parse
!macroend
!macro _UAC_ParseDefineFlags_IncludeFlag _outdef flag
!if ${_UAC_PDF${_outdef}_flags} & ${flag}
!insertmacro _UAC_definemath _UAC_PDF${_outdef}_r ${_UAC_PDF${_outdef}_r} | ${flag}
!endif
!macroend
!macro _UAC_ParseDefineFlagsToInt _outdef _in
!insertmacro _UAC_ParseDefineFlags_Begin _UAC_ParseDefineFlagsToInt_tmp "${_in}"
!define ${_outdef} ${_UAC_PDF_UAC_ParseDefineFlagsToInt_tmp_flags}
!insertmacro _UAC_ParseDefineFlags_End _UAC_ParseDefineFlagsToInt_tmp
!undef _UAC_ParseDefineFlagsToInt_tmp
!macroend
!macro _UAC_IncL
!insertmacro _UAC_definemath __UAC_L "${__UAC_L}" + 1
!macroend
!macro _UAC_AsUser_GenOp outvar op opparam1 opparam2
!define _UAC_AUGOGR_ID _UAC_AUGOGR_OP${outvar}${op}${opparam1}${opparam2}
!ifndef ${_UAC_AUGOGR_ID} ;Has this exact action been done before?
!if ${outvar} == $0
!define ${_UAC_AUGOGR_ID} $1
!else
!define ${_UAC_AUGOGR_ID} $0
!endif
!if "${opparam1}" == ""
!define _UAC_AUGOGR_OPP1 ${${_UAC_AUGOGR_ID}}
!define _UAC_AUGOGR_OPP2 ${opparam2}
!else
!define _UAC_AUGOGR_OPP1 ${opparam1}
!define _UAC_AUGOGR_OPP2 ${${_UAC_AUGOGR_ID}}
!endif
goto ${_UAC_AUGOGR_ID}_C
${_UAC_AUGOGR_ID}_F:
${op} ${_UAC_AUGOGR_OPP1} ${_UAC_AUGOGR_OPP2}
return
${_UAC_AUGOGR_ID}_C:
!undef _UAC_AUGOGR_OPP1
!undef _UAC_AUGOGR_OPP2
!endif
push ${${_UAC_AUGOGR_ID}}
!insertmacro UAC_AsUser_Call Label ${_UAC_AUGOGR_ID}_F ${UAC_SYNCREGISTERS}
StrCpy ${outvar} ${${_UAC_AUGOGR_ID}}
pop ${${_UAC_AUGOGR_ID}}
!undef _UAC_AUGOGR_ID
!macroend
!verbose pop
!endif /* UAC_HDR__INC */
@@ -1,28 +0,0 @@
!define nsProcess::FindProcess `!insertmacro nsProcess::FindProcess`
!macro nsProcess::FindProcess _FILE _ERR
nsProcess::_FindProcess /NOUNLOAD `${_FILE}`
Pop ${_ERR}
!macroend
!define nsProcess::KillProcess `!insertmacro nsProcess::KillProcess`
!macro nsProcess::KillProcess _FILE _ERR
nsProcess::_KillProcess /NOUNLOAD `${_FILE}`
Pop ${_ERR}
!macroend
!define nsProcess::CloseProcess `!insertmacro nsProcess::CloseProcess`
!macro nsProcess::CloseProcess _FILE _ERR
nsProcess::_CloseProcess /NOUNLOAD `${_FILE}`
Pop ${_ERR}
!macroend
!define nsProcess::Unload `!insertmacro nsProcess::Unload`
!macro nsProcess::Unload
nsProcess::_Unload
!macroend
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large Load Diff
-20
View File
@@ -1,20 +0,0 @@
//{{NO_DEPENDENCIES}}
// clang-format off
// Used by Status.rc
#define IDI_STATUS 107
#ifndef IDC_STATIC
#define IDC_STATIC -1
#endif
// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NO_MFC 130
#define _APS_NEXT_RESOURCE_VALUE 129
#define _APS_NEXT_COMMAND_VALUE 32771
#define _APS_NEXT_CONTROL_VALUE 1000
#define _APS_NEXT_SYMED_VALUE 110
#endif
#endif
Binary file not shown.

Before

Width:  |  Height:  |  Size: 32 KiB

-8
View File
@@ -1,8 +0,0 @@
#pragma once
// Including SDKDDKVer.h defines the highest available Windows platform.
// If you wish to build your application for a previous Windows platform, include WinSDKVer.h and
// set the _WIN32_WINNT macro to the platform you wish to support before including SDKDDKVer.h.
#include <sdkddkver.h>
-99
View File
@@ -1,99 +0,0 @@
# Copyright (C) 2016, Canonical Ltd.
# All rights reserved.
# This source code is licensed under the BSD-style license found in the
# LICENSE file in the root directory of this source tree. An additional grant
# of patent rights can be found in the PATENTS file in the same directory.
cmake_minimum_required(VERSION 3.12.1)
set(APP_NAME Status)
set(JS_APP_NAME StatusIm)
set(REACT_BUILD_STATIC_LIB ON)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DUNICODE -std=c++11")
if(STATUS_NO_LOGGING)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DSTATUS_NO_LOGGING")
endif()
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DUNICODE -std=c11")
set(CMAKE_INSTALL_PREFIX bin)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/${CMAKE_INSTALL_PREFIX}" CACHE PATH "Where to place compiled executables.")
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/CMakeModules/")
project(${APP_NAME} C CXX)
set(${APP_NAME}_BINARY_DIR ${CMAKE_RUNTIME_OUTPUT_DIRECTORY})
set(USED_QT_MODULES Core Concurrent Qml Quick WebSockets Svg)
include(QtConfiguration)
set(ICON_PNG_RESOURCE_PATH "${CMAKE_SOURCE_DIR}/../deployment/status-icon.png")
if (WIN32)
set(ICO_RESOURCE_PATH "${CMAKE_SOURCE_DIR}/../deployment/windows/status.ico")
set(APPLICATION_MAIN_RC_PATH "${CMAKE_SOURCE_DIR}/../deployment/windows/Status.rc")
configure_file(
${CMAKE_SOURCE_DIR}/../deployment/windows/Status.rc.in
${APPLICATION_MAIN_RC_PATH}
)
endif()
message(STATUS "EXTERNAL_MODULES_DIR: ${EXTERNAL_MODULES_DIR}")
string(REGEX MATCH "BUILD_FOR_BUNDLE" BUILD_FOR_BUNDLE "${CMAKE_CXX_FLAGS}")
# It is important to distinguish between directory hierarchies
# in release and dev builds. Release contains .env
# in the root dir of the build, while dev build's current dir
# is status-react/desktop/bin, hence the need
# to jump two levels up.
# This is required by react-native-config library which references ENVFILE
# from its own CMakeLists.txt file, so it will read the value set here
if(${BUILD_FOR_BUNDLE} MATCHES "BUILD_FOR_BUNDLE")
set(ENVFILE "/.env")
else()
set(ENVFILE "/../../.env")
endif()
foreach(external_module ${EXTERNAL_MODULES_DIR})
message(STATUS "external_module: ${external_module}")
add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../${external_module} ${CMAKE_CURRENT_BINARY_DIR}/${external_module})
endforeach(external_module)
add_subdirectory(reportApp)
# Import any new Qt modules that have been added by external dependencies
import_qt_modules()
# APPLICATION_MAIN_CPP_PATH contains absolute path to generated template copy of main.cpp for application executable
get_filename_component(APPLICATION_MAIN_CPP_PATH main.cpp ABSOLUTE)
set(REACTQT_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../node_modules/react-native/React)
include_directories(${REACTQT_DIR}/Layout)
add_subdirectory(${REACTQT_DIR}Qt/runtime/src ${CMAKE_CURRENT_BINARY_DIR}/lib)
add_subdirectory(${REACTQT_DIR}Qt/application/src ${CMAKE_CURRENT_BINARY_DIR}/bin)
if (Qt5_POSITION_INDEPENDENT_CODE)
SET(CMAKE_POSITION_INDEPENDENT_CODE ON)
endif(Qt5_POSITION_INDEPENDENT_CODE)
target_sources(${APP_NAME}
PRIVATE
"${CMAKE_CURRENT_LIST_DIR}/appconfig.h"
"${CMAKE_CURRENT_LIST_DIR}/appconfig.cpp")
#set(SOURCE_ROOT ${CMAKE_SOURCE_DIR})
include(CompleteBundle)
if (WIN32)
set(RUN_SCRIPT_FILE_NAME "run-app.bat")
else()
set(RUN_SCRIPT_FILE_NAME "run-app.sh")
endif()
configure_file(
${RUN_SCRIPT_FILE_NAME}.in
${CMAKE_CURRENT_BINARY_DIR}/${RUN_SCRIPT_FILE_NAME}
@ONLY
)
-12
View File
@@ -1,12 +0,0 @@
if(APPLE)
set(SCRIPT CompleteBundleOSX)
elseif(WIN32)
set(SCRIPT CompleteBundleWin)
elseif(UNIX)
set(SCRIPT CompleteBundleLinux)
endif(APPLE)
if(SCRIPT AND EXISTS ${CMAKE_SOURCE_DIR}/CMakeModules/${SCRIPT}.cmake.in)
configure_file(${CMAKE_SOURCE_DIR}/CMakeModules/${SCRIPT}.cmake.in ${SCRIPT}.cmake @ONLY)
include(${CMAKE_CURRENT_BINARY_DIR}/${SCRIPT}.cmake)
endif()
@@ -1,62 +0,0 @@
# windeployqt should be used here, but since we get the `Not implemented` error from it, we're trying to manually copy artifacts to output directory
set(TARGET_DIR "${@APP_NAME@_BINARY_DIR}")
##########################################################################################################
#
# NOTE: Remember to reflect any changes on the setup generation procedure in /deployment/windows/nsis/setup.nsi
#
##########################################################################################################
set(qtmodules Core Quick QuickTemplates2 QuickControls2 WebSockets Widgets Gui Network Svg Qml Concurrent)
if(USE_QTWEBKIT)
set(qtmodules ${qtmodules} Multimedia WebKit WebKitWidgets WebChannel)
add_custom_command(TARGET @APP_NAME@ POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
"@CONAN_BIN_DIRS_QT5-MXE@/QtWebProcess.exe"
${TARGET_DIR}
BYPRODUCTS ${TARGET_DIR}/QtWebProcess.exe)
endif()
foreach(qtmodule ${qtmodules})
message(STATUS "Copying ${qtmodule} module to ${TARGET_DIR}")
file(COPY "@CONAN_BIN_DIRS_QT5-MXE@/Qt5${qtmodule}.dll" DESTINATION "${TARGET_DIR}")
endforeach(qtmodule ${qtmodules})
if(EXISTS "@QTROOT@/translations")
message(STATUS "Copying translations module to ${TARGET_DIR}")
file(COPY "@QTROOT@/translations" DESTINATION "${TARGET_DIR}")
endif()
set(qtplugindirs "bearer" "platforms" "styles" "iconengines" "imageformats")
foreach(qtplugindir ${qtplugindirs})
message(STATUS "Copying plugin ${qtplugindir} to ${TARGET_DIR}/${qtplugindir}")
file(COPY "@CONAN_BIN_DIRS_QT5-MXE@/../plugins/${qtplugindir}/" DESTINATION "${TARGET_DIR}/${qtplugindir}")
endforeach()
set(qtqmldirs "QtQuick" "QtQuick.2" "QtGraphicalEffects" "QtWebSockets" "QtQml")
if(USE_QTWEBKIT)
set(qtqmldirs ${qtqmldirs} "QtWebKit" "QtWebChannel")
endif()
foreach(qtqmldir ${qtqmldirs})
message(STATUS "Copying QML dir for ${qtqmldir} to ${TARGET_DIR}/${qtqmldir}")
file(COPY "@CONAN_BIN_DIRS_QT5-MXE@/../qml/${qtqmldir}/" DESTINATION "${TARGET_DIR}/${qtqmldir}")
endforeach()
set(deps_qt5 "libpng16-16" "libharfbuzz-0" "zlib1" "libpcre2-16-0"
"libpcre-1" "libcrypto-1_1-x64" "libssl-1_1-x64" "libfreetype-6"
"libglib-2.0-0" "libstdc++-6" "libbz2" "libintl-8" "libiconv-2"
"icuin56" "icuuc56" "icudt56" "libjpeg-9" "libsqlite3-0" "libwebp-5" "libgcc_s_seh-1")
set(TOOLCHAIN_BINDIRS "@CONAN_BIN_DIRS_MXETOOLCHAIN-X86_64-W64-MINGW32@")
separate_arguments(TOOLCHAIN_BINDIRS)
foreach(lib ${deps_qt5})
foreach(bindir ${TOOLCHAIN_BINDIRS})
set(lib_full_path "${bindir}/${lib}.dll")
if(EXISTS "${lib_full_path}")
break()
endif()
endforeach()
if(NOT EXISTS "${lib_full_path}")
set(lib_full_path "@CONAN_BIN_DIRS_QT5-MXE@/${lib}.dll")
endif()
message(STATUS "Copying ${lib_full_path} to ${TARGET_DIR}")
file(COPY ${lib_full_path} DESTINATION ${TARGET_DIR})
endforeach(lib ${deps_qt5})
@@ -1,86 +0,0 @@
macro(import_qt_modules)
set(REQUIRED_QT_VERSION "5.9.1")
set(QTCONFIGROOT ${QTROOT}/lib/cmake/Qt5)
foreach(COMP ${USED_QT_MODULES})
set(mod Qt5${COMP})
# look for the config files in the QtConfigRoot defined above
set(${mod}_DIR ${QTCONFIGROOT}${COMP})
# look for the actual package
find_package(${mod} ${REQUIRED_QT_VERSION} REQUIRED)
#message("${mod}_INCLUDE_DIRS: include_directories(${${mod}_INCLUDE_DIRS})")
include_directories(${${mod}_INCLUDE_DIRS})
if (${COMP} STREQUAL "Quick")
# We need to include the private headers for QZipWriter. If in the future we can't use that class anymore, we can always resort to the QuaZIP OSS library
include_directories(${${mod}_PRIVATE_INCLUDE_DIRS})
endif()
list(APPEND QT5_LIBRARIES ${${mod}_LIBRARIES})
list(APPEND QT5_CFLAGS ${${mod}_EXECUTABLE_COMPILE_FLAGS})
endforeach(COMP ${USED_QT_MODULES})
endmacro(import_qt_modules)
if(WIN32)
# Download automatically, you can also just copy the conan.cmake file
# TODO: Create packages of qt5 for Linux and MacOS too, so that we can rely strictly on this branch of code
if(NOT EXISTS "${CMAKE_BINARY_DIR}/conan.cmake")
message(STATUS "Downloading conan.cmake from https://github.com/conan-io/cmake-conan")
file(DOWNLOAD "https://raw.githubusercontent.com/conan-io/cmake-conan/9cc97acda619b7917f140415241785a864482b11/conan.cmake"
"${CMAKE_BINARY_DIR}/conan.cmake")
endif()
include(${CMAKE_BINARY_DIR}/conan.cmake)
conan_check()
if(USE_QTWEBKIT)
set(_QT_PACKAGE_OPTIONS "qt5-mxe:webkit=True")
endif()
conan_cmake_run(REQUIRES qt5-mxe/5.11.2@status-im/stable
PROFILE ../node_modules/status-conan/profiles/status-mingw32-x86_64
SETTINGS "qt5-mxe:os=Windows" "qt5-mxe:arch=x86_64"
OPTIONS ${_QT_PACKAGE_OPTIONS}
BUILD never)
set(QTROOT "${CONAN_QT5-MXE_ROOT}")
else(WIN32)
set(QTROOT "$ENV{QT_PATH}")
endif(WIN32)
if(NOT EXISTS ${QTROOT}/bin/qt.conf)
if(EXISTS ${QTROOT}/gcc_64/bin/qt.conf)
set(QTROOT "${QTROOT}/gcc_64")
elseif(EXISTS ${QTROOT}/clang_64/bin/qt.conf)
set(QTROOT "${QTROOT}/clang_64")
else()
message(FATAL_ERROR "Could not find qt.conf in ${QTROOT}/bin nor in ${QTROOT}/clang_64/bin nor in ${QTROOT}/gcc_64/bin. Is QTROOT correctly defined?")
endif()
endif()
if(WIN32)
set(WINARCHSTR ARCHSTR windows-x86_64)
endif(WIN32)
message(STATUS "Qt root directory: ${QTROOT}")
list(APPEND CMAKE_FIND_ROOT_PATH ${QTROOT})
list(APPEND CMAKE_PREFIX_PATH ${QTROOT})
include_directories(${QTROOT}/include)
import_qt_modules()
if(QT5_CFLAGS)
list(REMOVE_DUPLICATES QT5_CFLAGS)
if(WIN32)
list(REMOVE_ITEM QT5_CFLAGS -fPIC)
endif(WIN32)
endif(QT5_CFLAGS)
message(STATUS "Qt version: ${Qt5Core_VERSION_STRING}")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${QT5_CFLAGS}")
set(CMAKE_REQUIRED_LIBRARIES ${QT5_LIBRARIES})
-19
View File
@@ -1,19 +0,0 @@
# Toolchain file for building for Windows from an Ubuntu Linux system.
#
# Typical usage:
# *) install cross compiler: `sudo apt-get install mingw-w64 g++-mingw-w64`
# *) cmake -DCMAKE_TOOLCHAIN_FILE=~/Toolchain-Ubuntu-mingw64.cmake ..
message(STATUS "Cross-compiling for Windows")
set(CMAKE_SYSTEM_NAME Windows)
if(NOT "${CMAKE_HOST_SYSTEM_NAME}" STREQUAL "Linux")
message(FATAL_ERROR "Can only cross-compile to Windows from Linux")
endif()
set(USE_QTWEBKIT OFF)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/toolchain/")
include(conanbuildinfo)
#conan_basic_setup()
conan_global_flags()
-76
View File
@@ -1,76 +0,0 @@
#include "appconfig.h"
#include <QLoggingCategory>
#include <QSettings>
const QStringList loggingCategories =
{"UIManager",
"Flexbox",
"WebSocketModule",
"Networking",
"ViewManager",
"RCTNotification",
"default",
"RCTStatus",
"jsserver",
"status"};
const QString SETTINGS_GROUP_NAME = "im/status";
const QString AppConfig::LOGGING_ENABLED = "logging_enabled";
Q_LOGGING_CATEGORY(APPCONFIG, "AppConfig")
AppConfig AppConfig::appConfig;
AppConfig::AppConfig()
: settings("Status.im", "StatusDesktop") {
settings.beginGroup(SETTINGS_GROUP_NAME);
// Set default values
if (settings.value(LOGGING_ENABLED).isNull()) {
settings.setValue(LOGGING_ENABLED, false);
}
QStringList keys = settings.allKeys();
for (int i = 0; i < keys.size(); ++i) {
processFx(keys[i], settings.value(keys[i]));
}
}
AppConfig& AppConfig::inst() {
return appConfig;
}
QVariant AppConfig::getValue(const QString& name) const {
return settings.value(name);
}
void AppConfig::setValue(const QString& name, const QVariant& value) {
processFx(name, value);
settings.setValue(name, value);
}
// This fn is for processing side-effects of a particular value
void AppConfig::processFx(const QString& name, const QVariant& value) const {
//qCDebug(APPCONFIG) << "### processFx group" << settings.group() << " " << name << ": " << value;
if (name == LOGGING_ENABLED) {
bool enabled = value.toBool();
//qCDebug(APPCONFIG) << "### processFx" << name << ": " << value << ": " << enabled;
QLoggingCategory::setFilterRules(getLoggingFilterRules(enabled));
}
}
QString AppConfig::getLoggingFilterRules(bool enabled) const {
if (enabled) {
return "UIManager=false\nFlexbox=false\nViewManager=false\nNetworking=false\nWebSocketModule=false";
}
else {
QString filterRules;
for (int i = 0; i < loggingCategories.size(); ++i) {
filterRules += (loggingCategories.at(i) + "=false\n");
}
return filterRules;
}
}
-31
View File
@@ -1,31 +0,0 @@
#ifndef APPCONFIG_H
#define APPCONFIG_H
#include <QString>
#include <QVariant>
#include <QSettings>
// This class is intended to store app configuration
// modifiable from JS side
// Currently, only logging-related settings are here
// that are used by react-native-desktop-config module
class AppConfig {
public:
static AppConfig& inst();
QVariant getValue(const QString& name) const;
void setValue(const QString& name, const QVariant& value);
const static QString LOGGING_ENABLED;
private:
AppConfig();
static AppConfig appConfig;
QSettings settings;
QString getLoggingFilterRules(bool enabled) const;
void processFx(const QString& name, const QVariant& value) const;
};
#endif // APPCONFIG_H
-36
View File
@@ -1,36 +0,0 @@
@rem Copyright (c) 2017-present, Status Research and Development GmbH.
@rem All rights reserved.
@rem
@rem This source code is licensed under the BSD-style license found in the
@rem LICENSE file in the root directory of this source tree. An additional grant
@rem of patent rights can be found in the PATENTS file in the same directory.
@echo off
setlocal EnableDelayedExpansion
set "option="
for %%a in (%*) do (
if not defined option (
set arg=%%a
if "!arg:~0,1!" equ "-" set "option=!arg!"
) else (
set "option!option!=%%a"
set "option="
)
)
SET option
@echo on
echo "build.bat external modules paths: "%option-e%
echo "build.bat JS bundle path: "%option-j%
echo "build.bat desktop fonts: "%option-f%
echo "build.bat desktop images: "%option-i%
echo "build.bat cmake generator: "%option-g%
@rem Workaround
@rem rm -rf CMakeFiles CMakeCache.txt cmake_install.cmake Makefile
@rem Build project
echo %CD%
cmake -DCMAKE_BUILD_TYPE=Debug -G %option-g% -DEXTERNAL_MODULES_DIR=%option-e% -DJS_BUNDLE_PATH=%option-j% -DDESKTOP_FONTS=%option-f% -DDESKTOP_IMAGES=%option-i% . && cmake --build .
-49
View File
@@ -1,49 +0,0 @@
#!/usr/bin/env bash
# Copyright (C) 2016, Canonical Ltd.
# All rights reserved.
# This source code is licensed under the BSD-style license found in the
# LICENSE file in the root directory of this source tree. An additional grant
# of patent rights can be found in the PATENTS file in the same directory.
# XXX: Don't move this script
cd $(dirname $0)
while (( "$#" )); do
if [[ $1 == "-e" ]]; then
shift
ExternalModulesPaths="$1"
fi
if [[ $1 == "-j" ]]; then
shift
JsBundlePath="$1"
fi
if [[ $1 == "-f" ]]; then
shift
desktopFonts="$1"
fi
if [[ $1 == "-i" ]]; then
shift
desktopImages="$1"
fi
shift
done
echo "build.sh external modules paths: "$ExternalModulesPaths
echo "build.sh JS bundle path: "$JsBundlePath
echo "build.sh desktop fonts: "$desktopFonts
echo "build.sh desktop images: "$desktopImages
# Workaround
rm -rf CMakeFiles CMakeCache.txt cmake_install.cmake Makefile
# Build project
cmake -DCMAKE_BUILD_TYPE=Debug \
-DEXTERNAL_MODULES_DIR="$ExternalModulesPaths" \
-DJS_BUNDLE_PATH="$JsBundlePath" \
-DDESKTOP_FONTS="$desktopFonts" \
-DDESKTOP_IMAGES="$desktopImages" \
-DCMAKE_INSTALL_COMPONENT='' \
. && \
make
-216
View File
@@ -1,216 +0,0 @@
{
"name": "StatusIm-Desktop",
"version": "0.0.1",
"private": true,
"scripts": {
"start": "node node_modules/react-native/local-cli/cli.js start",
"prepare": "patch-package"
},
"dependencies": {
"assert": "^1.4.1",
"bignumber.js": "git+https://github.com/status-im/bignumber.js.git#v4.0.2-status",
"buffer": "^3.6.0",
"chance": "^1.1.3",
"create-react-class": "^15.6.2",
"emojilib": "^2.2.9",
"eth-phishing-detect": "^1.1.13",
"events": "^1.1.1",
"functional-red-black-tree": "^1.0.1",
"google-breakpad": "git+https://github.com/status-im/google-breakpad.git#v0.9.0",
"hi-base32": "^0.5.0",
"i18n-js": "^3.5.0",
"identicon.js": "git+https://github.com/status-im/identicon.js.git#v1.2.1-status",
"metro": "^0.48.1",
"nfc-react-native": "git+https://github.com/status-im/nfc-react-native.git#v0.3.8-status",
"qrcode": "^1.4.4",
"react": "^16.12.0",
"react-dom": "^16.12.0",
"react-native": "git+https://github.com/status-im/react-native-desktop.git#v0.57.8_11",
"react-native-background-timer": "^2.0.0",
"react-native-camera": "^3.9.0",
"react-native-config": "git+https://github.com/status-im/react-native-config.git#v0.11.2-status",
"react-native-dialogs": "^0.0.20",
"react-native-fetch-polyfill": "^1.1.2",
"react-native-fs": "git+https://github.com/status-im/react-native-fs.git#v2.9.7-status",
"react-native-gesture-handler": "^1.5.0",
"react-native-image-crop-picker": "^0.26.1",
"react-native-image-resizer": "^1.1.0",
"react-native-keychain": "git+https://github.com/status-im/react-native-keychain.git#v.3.0.0-4-status",
"react-native-languages": "git+https://github.com/status-im/react-native-languages.git#v0.1.1-status",
"react-native-navigation-twopane": "git+https://github.com/status-im/react-native-navigation-twopane.git#v0.0.2-status",
"react-native-os": "^1.1.0",
"react-native-splash-screen": "^3.0.6",
"react-native-webview-bridge": "git+https://github.com/status-im/react-native-webview-bridge.git#0.33.16-status-rn049-desktop",
"react-navigation": "^3.11.0",
"status-conan": "git+https://github.com/status-im/status-conan.git#v1.0.0",
"web3-utils": "^1.2.4"
},
"devDependencies": {
"@babel/core": "^7.7.2",
"@babel/generator": "^7.7.2",
"@babel/helper-builder-react-jsx": "^7.7.0",
"@babel/plugin-transform-block-scoping": "7.0.0",
"@babel/preset-env": "^7.7.1",
"@babel/register": "^7.7.0",
"babel-preset-react-native": "^5.0.2",
"coveralls": "^3.0.7",
"metro-react-native-babel-preset": "^0.57.0",
"nyc": "^14.1.1",
"patch-package": "^5.1.1",
"rn-snoopy": "git+https://github.com/status-im/rn-snoopy.git#v2.0.2-status"
},
"optionalDependencies": {
"appdmg": "^0.6.0"
},
"desktopExternalModules": [
"node_modules/react-native-languages/desktop",
"node_modules/react-native-config/desktop",
"node_modules/react-native-fs/desktop",
"node_modules/react-native-webview-bridge/desktop",
"node_modules/react-native-keychain/desktop",
"modules/react-native-status/desktop",
"modules/react-native-desktop-linking/desktop",
"modules/react-native-desktop-menu/desktop",
"modules/react-native-desktop-config/desktop",
"modules/react-native-desktop-shortcuts/desktop",
"modules/react-native-desktop-notification/desktop",
"modules/react-native-desktop-gesture-handler/desktop",
"node_modules/google-breakpad"
],
"desktopFonts": [
"../../../../../resources/fonts/Inter-BlackItalic.otf",
"../../../../../resources/fonts/Inter-Black.otf",
"../../../../../resources/fonts/Inter-BoldItalic.otf",
"../../../../../resources/fonts/Inter-Bold.otf",
"../../../../../resources/fonts/Inter-ExtraBoldItalic.otf",
"../../../../../resources/fonts/Inter-ExtraBold.otf",
"../../../../../resources/fonts/Inter-ExtraLight-BETA.otf",
"../../../../../resources/fonts/Inter-ExtraLightItalic-BETA.otf",
"../../../../../resources/fonts/Inter-Italic.otf",
"../../../../../resources/fonts/Inter-Light-BETA.otf",
"../../../../../resources/fonts/Inter-LightItalic-BETA.otf",
"../../../../../resources/fonts/Inter-MediumItalic.otf",
"../../../../../resources/fonts/Inter-Medium.otf",
"../../../../../resources/fonts/Inter-Regular.otf",
"../../../../../resources/fonts/Inter-SemiBoldItalic.otf",
"../../../../../resources/fonts/Inter-SemiBold.otf",
"../../../../../resources/fonts/Inter-Thin-BETA.otf",
"../../../../../resources/fonts/Inter-ThinItalic-BETA.otf"
],
"desktopImages": [
"../../../../../desktop/resources/add.png",
"../../../../../desktop/resources/address.png",
"../../../../../desktop/resources/add_contact.png",
"../../../../../desktop/resources/arrow_left.png",
"../../../../../desktop/resources/arrow_right.png",
"../../../../../desktop/resources/arrow_up.png",
"../../../../../desktop/resources/back.png",
"../../../../../desktop/resources/backspace.png",
"../../../../../desktop/resources/bell.png",
"../../../../../desktop/resources/browser.png",
"../../../../../desktop/resources/camera.png",
"../../../../../desktop/resources/cancel.png",
"../../../../../desktop/resources/change.png",
"../../../../../desktop/resources/check.png",
"../../../../../desktop/resources/close.png",
"../../../../../desktop/resources/commands.png",
"../../../../../desktop/resources/copy.png",
"../../../../../desktop/resources/corner_left_bottom.png",
"../../../../../desktop/resources/corner_left_top.png",
"../../../../../desktop/resources/corner_right_bottom.png",
"../../../../../desktop/resources/corner_right_top.png",
"../../../../../desktop/resources/dapp.png",
"../../../../../desktop/resources/delete.png",
"../../../../../desktop/resources/desktop.png",
"../../../../../desktop/resources/download.png",
"../../../../../desktop/resources/dropdown.png",
"../../../../../desktop/resources/dropdown_up.png",
"../../../../../desktop/resources/edit.png",
"../../../../../desktop/resources/filter.png",
"../../../../../desktop/resources/fingerprint.png",
"../../../../../desktop/resources/flash.png",
"../../../../../desktop/resources/flash_active.png",
"../../../../../desktop/resources/group_chat.png",
"../../../../../desktop/resources/help.png",
"../../../../../desktop/resources/history.png",
"../../../../../desktop/resources/home.png",
"../../../../../desktop/resources/home_1.png",
"../../../../../desktop/resources/icon_action_back.png",
"../../../../../desktop/resources/icon_action_forward.png",
"../../../../../desktop/resources/icon_action_fullscreen_collapse.png",
"../../../../../desktop/resources/icon_action_fullscreen_expand.png",
"../../../../../desktop/resources/icon_arrow_top.png",
"../../../../../desktop/resources/icon_avatar.png",
"../../../../../desktop/resources/icon_check_on.png",
"../../../../../desktop/resources/icon_close_light_gray.png",
"../../../../../desktop/resources/icon_forward_gray.png",
"../../../../../desktop/resources/icon_lock_gray.png",
"../../../../../desktop/resources/icon_lock_white.png",
"../../../../../desktop/resources/icon_menu_group.png",
"../../../../../desktop/resources/icon_money_white.png",
"../../../../../desktop/resources/icon_muted.png",
"../../../../../desktop/resources/icon_notifications_on.png",
"../../../../../desktop/resources/icon_phone_white.png",
"../../../../../desktop/resources/ic_background.png",
"../../../../../desktop/resources/ic_foreground.png",
"../../../../../desktop/resources/ic_stat_status_notification.png",
"../../../../../desktop/resources/info.png",
"../../../../../desktop/resources/in_contacts.png",
"../../../../../desktop/resources/keycard.png",
"../../../../../desktop/resources/keycard_logo.png",
"../../../../../desktop/resources/language.png",
"../../../../../desktop/resources/launch_logo.png",
"../../../../../desktop/resources/link.png",
"../../../../../desktop/resources/logo.png",
"../../../../../desktop/resources/log_out.png",
"../../../../../desktop/resources/mailserver.png",
"../../../../../desktop/resources/make_admin.png",
"../../../../../desktop/resources/max.png",
"../../../../../desktop/resources/message.png",
"../../../../../desktop/resources/mobile.png",
"../../../../../desktop/resources/more.png",
"../../../../../desktop/resources/network.png",
"../../../../../desktop/resources/next.png",
"../../../../../desktop/resources/notification.png",
"../../../../../desktop/resources/one_on_one_chat.png",
"../../../../../desktop/resources/password.png",
"../../../../../desktop/resources/paste.png",
"../../../../../desktop/resources/photo.png",
"../../../../../desktop/resources/profile.png",
"../../../../../desktop/resources/public_chat.png",
"../../../../../desktop/resources/qr.png",
"../../../../../desktop/resources/receive.png",
"../../../../../desktop/resources/refresh.png",
"../../../../../desktop/resources/remove_contact.png",
"../../../../../desktop/resources/reply.png",
"../../../../../desktop/resources/rotate_camera.png",
"../../../../../desktop/resources/search.png",
"../../../../../desktop/resources/security.png",
"../../../../../desktop/resources/send.png",
"../../../../../desktop/resources/settings.png",
"../../../../../desktop/resources/settings_advanced.png",
"../../../../../desktop/resources/share.png",
"../../../../../desktop/resources/stickers.png",
"../../../../../desktop/resources/text.png",
"../../../../../desktop/resources/tiny_arrow_down.png",
"../../../../../desktop/resources/tiny_check.png",
"../../../../../desktop/resources/tiny_clear.png",
"../../../../../desktop/resources/tiny_edit.png",
"../../../../../desktop/resources/tiny_external.png",
"../../../../../desktop/resources/tiny_group.png",
"../../../../../desktop/resources/tiny_lock.png",
"../../../../../desktop/resources/tiny_lock_broken.png",
"../../../../../desktop/resources/tiny_new_contact.png",
"../../../../../desktop/resources/tiny_pending.png",
"../../../../../desktop/resources/tiny_public.png",
"../../../../../desktop/resources/tiny_settings.png",
"../../../../../desktop/resources/tiny_tribute_to_talk.png",
"../../../../../desktop/resources/tribute_to_talk.png",
"../../../../../desktop/resources/two_arrows.png",
"../../../../../desktop/resources/username.png",
"../../../../../desktop/resources/user_profile.png",
"../../../../../desktop/resources/user_profile_1.png",
"../../../../../desktop/resources/wallet.png",
"../../../../../desktop/resources/warning.png"
]
}
File diff suppressed because it is too large Load Diff
-545
View File
@@ -1,545 +0,0 @@
/**
* Copyright (C) 2016, Canonical Ltd.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*/
// #define BUILD_FOR_BUNDLE
#include <QCommandLineParser>
#include <QDirIterator>
#include <QFile>
#include <QFontDatabase>
#include <QApplication>
#include <QMutexLocker>
#include <QProcess>
#include <QQuickView>
#include <QStandardPaths>
#include <QTimer>
#include <QUrl>
#include "attachedproperties.h"
#include "reactitem.h"
#include "rootview.h"
#include "utilities.h"
#include "exceptionglobalhandler.h"
#include "appconfig.h"
Q_DECLARE_LOGGING_CATEGORY(JSSERVER)
Q_DECLARE_LOGGING_CATEGORY(STATUS)
Q_LOGGING_CATEGORY(JSSERVER, "jsserver")
Q_LOGGING_CATEGORY(STATUS, "status")
static QStringList consoleOutputStrings;
static QMutex consoleOutputMutex;
#ifdef BUILD_FOR_BUNDLE
bool nodeJsServerStarted = false;
QProcess *g_nodeJsServerProcess = nullptr;
#define NODEJS_SERVER_NAME "ubuntu-server"
#endif
const int MAIN_WINDOW_WIDTH = 1024;
const int MAIN_WINDOW_HEIGHT = 768;
const QString CRASH_REPORT_EXECUTABLE = QStringLiteral("reportApp");
const char *ENABLE_LOG_FILE_ENV_VAR_NAME = "STATUS_LOG_FILE_ENABLED";
const char *LOG_FILE_PATH_ENV_VAR_NAME = "STATUS_LOG_PATH";
// TODO: some way to change while running
class ReactNativeProperties : public QObject {
Q_OBJECT
Q_PROPERTY(
bool liveReload READ liveReload WRITE setLiveReload NOTIFY liveReloadChanged)
Q_PROPERTY(
QUrl codeLocation READ codeLocation WRITE setCodeLocation NOTIFY codeLocationChanged)
Q_PROPERTY(
QString pluginsPath READ pluginsPath WRITE setPluginsPath NOTIFY pluginsPathChanged)
Q_PROPERTY(
QString executor READ executor WRITE setExecutor NOTIFY executorChanged)
Q_PROPERTY(
QVariantMap initialProps READ initialProps WRITE setInitialProps NOTIFY initialPropsChanged)
public:
ReactNativeProperties(QObject *parent = nullptr) : QObject(parent) {
m_codeLocation = m_packagerTemplate.arg(m_packagerHost).arg(m_packagerPort);
}
bool liveReload() const { return m_liveReload; }
void setLiveReload(bool liveReload) {
if (m_liveReload == liveReload)
return;
m_liveReload = liveReload;
Q_EMIT liveReloadChanged();
}
QUrl codeLocation() const { return m_codeLocation; }
void setCodeLocation(const QUrl &codeLocation) {
if (m_codeLocation == codeLocation)
return;
m_codeLocation = codeLocation;
Q_EMIT codeLocationChanged();
}
QString pluginsPath() const { return m_pluginsPath; }
void setPluginsPath(const QString &pluginsPath) {
if (m_pluginsPath == pluginsPath)
return;
m_pluginsPath = pluginsPath;
Q_EMIT pluginsPathChanged();
}
QString executor() const { return m_executor; }
void setExecutor(const QString &executor) {
if (m_executor == executor)
return;
m_executor = executor;
Q_EMIT executorChanged();
}
QVariantMap initialProps() const { return m_initialProps; }
void setInitialProps(const QVariantMap &initialProps) {
if (m_initialProps == initialProps)
return;
m_initialProps = initialProps;
Q_EMIT initialPropsChanged();
}
QString packagerHost() const { return m_packagerHost; }
void setPackagerHost(const QString &packagerHost) {
if (m_packagerHost == packagerHost)
return;
m_packagerHost = packagerHost;
setCodeLocation(m_packagerTemplate.arg(m_packagerHost).arg(m_packagerPort));
}
QString packagerPort() const { return m_packagerPort; }
void setPackagerPort(const QString &packagerPort) {
if (m_packagerPort == packagerPort)
return;
m_packagerPort = packagerPort;
setCodeLocation(m_packagerTemplate.arg(m_packagerHost).arg(m_packagerPort));
}
void setLocalSource(const QString &source) {
if (m_localSource == source)
return;
// overrides packager*
if (source.startsWith("file:")) {
setCodeLocation(source);
} else {
QFileInfo fi(source);
if (!fi.exists()) {
qCWarning(STATUS) << "Attempt to set non-existent local source file";
return;
}
setCodeLocation(QUrl::fromLocalFile(fi.absoluteFilePath()));
setLiveReload(false);
}
}
Q_SIGNALS:
void liveReloadChanged();
void codeLocationChanged();
void pluginsPathChanged();
void executorChanged();
void initialPropsChanged();
private:
bool m_liveReload = false;
QString m_packagerHost = "localhost";
QString m_packagerPort = "8081";
QString m_localSource;
QString m_packagerTemplate =
"http://%1:%2/index.desktop.bundle?platform=desktop&dev=true";
QUrl m_codeLocation;
QString m_pluginsPath;
#ifdef BUILD_FOR_BUNDLE
QString m_executor = "RemoteServerConnection";
#else
QString m_executor = "LocalServerConnection";
#endif
QVariantMap m_initialProps;
};
void saveMessage(QtMsgType type, const QMessageLogContext &context,
const QString &msg);
void writeLogsToFile();
void writeLogFromJSServer(const QString &msg);
void writeSingleLineLogFromJSServer(const QString &msg);
#ifdef BUILD_FOR_BUNDLE
void killZombieJsServer();
bool runNodeJsServer();
#endif
void loadFontsFromResources() {
QDirIterator it(":", QDirIterator::Subdirectories);
while (it.hasNext()) {
QString resourceFile = it.next();
if (resourceFile.endsWith(".otf", Qt::CaseInsensitive) ||
resourceFile.endsWith(".ttf", Qt::CaseInsensitive)) {
qint32 fontId = QFontDatabase::addApplicationFont(resourceFile);
if (Q_UNLIKELY(fontId == -1)) {
qCDebug(STATUS) << "Unable to install font" << resourceFile;
}
}
}
}
void exceptionPostHandledCallback() {
#ifdef BUILD_FOR_BUNDLE
if (g_nodeJsServerProcess) {
g_nodeJsServerProcess->kill();
}
#endif
}
bool redirectLogIntoFile() {
#ifdef BUILD_FOR_BUNDLE
return true;
#else
return qEnvironmentVariable(ENABLE_LOG_FILE_ENV_VAR_NAME, "") ==
QStringLiteral("1");
#endif
}
QString getDataStoragePath() {
QString statusDataDir = qgetenv("STATUS_DATA_DIR");
QString dataStoragePath;
if (!statusDataDir.isEmpty()) {
dataStoragePath = statusDataDir;
} else {
dataStoragePath = QStandardPaths::writableLocation(QStandardPaths::AppLocalDataLocation);
}
QDir dir(dataStoragePath);
if (!dir.exists()) {
dir.mkpath(".");
}
return dataStoragePath;
}
int main(int argc, char **argv) {
QGuiApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
QApplication app(argc, argv);
QCoreApplication::setApplicationName("Status");
// Init AppConfig
AppConfig::inst().getValue(AppConfig::LOGGING_ENABLED);
QString appPath = QCoreApplication::applicationDirPath();
QString dataStoragePath = getDataStoragePath();
#ifdef BUILD_FOR_BUNDLE
if (qgetenv("STATUS_DATA_DIR").isEmpty()) {
killZombieJsServer();
}
#else
dataStoragePath = "";
#endif
ExceptionGlobalHandler exceptionHandler(
appPath + QDir::separator() + CRASH_REPORT_EXECUTABLE,
exceptionPostHandledCallback, dataStoragePath);
Q_INIT_RESOURCE(react_resources);
loadFontsFromResources();
if (redirectLogIntoFile()) {
qInstallMessageHandler(saveMessage);
}
//qCDebug(STATUS) << "###STATUS_NO_LOGGING";
#ifdef BUILD_FOR_BUNDLE
if (!runNodeJsServer()) {
if (g_nodeJsServerProcess->state() == QProcess::NotRunning) {
// If we failed to start the Node.js server (happens on Windows if the Node.js server process was previously running), let's do a final attempt
delete g_nodeJsServerProcess;
if (!runNodeJsServer()) {
return 1;
}
}
}
app.setWindowIcon(QIcon(":/icon.png"));
#endif
QQuickView view;
ReactNativeProperties *rnp = new ReactNativeProperties(&view);
QProcessEnvironment env = QProcessEnvironment::systemEnvironment();
QVariantMap initialProps;
QString statusNodePort = env.value("STATUS_NODE_PORT");
QString statusDataDir = env.value("STATUS_DATA_DIR");
if (!statusNodePort.isEmpty()) {
initialProps["STATUS_NODE_PORT"] = statusNodePort;
}
if (!statusDataDir.isEmpty()) {
initialProps["STATUS_DATA_DIR"] = statusDataDir;
}
rnp->setInitialProps(initialProps);
#ifdef BUILD_FOR_BUNDLE
rnp->setCodeLocation("file:" + QGuiApplication::applicationDirPath() +
"/assets");
#endif
utilities::registerReactTypes();
QCommandLineParser p;
p.setApplicationDescription("React Native host application");
p.addHelpOption();
p.addOptions({
{{"R", "live-reload"}, "Enable live reload."},
{{"H", "host"}, "Set packager host address.", rnp->packagerHost()},
{{"P", "port"}, "Set packager port number.", rnp->packagerPort()},
{{"L", "local"}, "Set path to the local packaged source", "not set"},
{{"M", "plugins-path"}, "Set path to node modules", "./plugins"},
{{"E", "executor"}, "Set Javascript executor", rnp->executor()},
});
p.process(app);
rnp->setLiveReload(p.isSet("live-reload"));
if (p.isSet("host"))
rnp->setPackagerHost(p.value("host"));
if (p.isSet("port"))
rnp->setPackagerPort(p.value("port"));
if (p.isSet("local"))
rnp->setLocalSource(p.value("local"));
if (p.isSet("plugins-path"))
rnp->setPluginsPath(p.value("plugins-path"));
if (p.isSet("executor"))
rnp->setExecutor(p.value("executor"));
view.rootContext()->setContextProperty("ReactNativeProperties", rnp);
view.setSource(QUrl("qrc:///main.qml"));
view.setResizeMode(QQuickView::SizeRootObjectToView);
view.resize(MAIN_WINDOW_WIDTH, MAIN_WINDOW_HEIGHT);
view.show();
QTimer flushLogsToFileTimer;
if (redirectLogIntoFile()) {
flushLogsToFileTimer.setInterval(500);
QObject::connect(&flushLogsToFileTimer, &QTimer::timeout,
[=]() { writeLogsToFile(); });
flushLogsToFileTimer.start();
}
return app.exec();
}
QString getLogFilePath() {
QString logFilePath;
#ifdef BUILD_FOR_BUNDLE
logFilePath = getDataStoragePath() + QDir::separator() + "Status.log";
#else
logFilePath = qEnvironmentVariable(LOG_FILE_PATH_ENV_VAR_NAME, "");
if (logFilePath.isEmpty()) {
logFilePath = getDataStoragePath() + QDir::separator() + "StatusDev.log";
}
#endif
return logFilePath;
}
void writeLogsToFile() {
QMutexLocker locker(&consoleOutputMutex);
if(consoleOutputStrings.isEmpty())
return;
QFile logFile(getLogFilePath());
if (logFile.open(QIODevice::WriteOnly | QIODevice::Append)) {
for (QString message : consoleOutputStrings) {
logFile.write(message.toStdString().c_str());
}
consoleOutputStrings.clear();
logFile.flush();
logFile.close();
}
}
#ifdef BUILD_FOR_BUNDLE
#ifdef Q_OS_WIN
#include <windows.h>
#include <tlhelp32.h>
bool IsProcessRunning(const wchar_t *processName) {
bool exists = false;
PROCESSENTRY32 entry = { sizeof(PROCESSENTRY32) };
HANDLE snapshot = ::CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, 0);
if (snapshot != NULL) {
if (::Process32First(snapshot, &entry)) {
do {
if (!wcsicmp(entry.szExeFile, processName)) {
exists = true;
break;
}
} while (::Process32Next(snapshot, &entry));
}
::CloseHandle(snapshot);
}
return exists;
}
#endif
void killZombieJsServer() {
// Ensure that a zombie Node.js server process is not still running in the background before we spawn a new one
QString cmd;
#ifdef Q_OS_LINUX
cmd = QString("pkill -f %1").arg(NODEJS_SERVER_NAME);
#elif defined(Q_OS_MAC)
cmd = QString("killall -9 %1").arg(NODEJS_SERVER_NAME);
#elif defined(Q_OS_WIN)
#define _CAT(A, B) A##B
#define _W(A) _CAT(L, #A)
WCHAR exeName[_MAX_PATH];
wsprintf(exeName, L"%s.exe", _W(NODEJS_SERVER_NAME));
if (IsProcessRunning(exeName)) {
qCDebug(STATUS) << NODEJS_SERVER_NAME << "is running, killing it";
::ShellExecuteW(NULL, NULL, L"tskill", _W(NODEJS_SERVER_NAME), NULL, SW_HIDE);
} else {
qCDebug(STATUS) << NODEJS_SERVER_NAME << "is not running";
}
#endif
if (!cmd.isEmpty()) {
qCDebug(STATUS) << "Running " << cmd;
QByteArray cmdArray = cmd.toLocal8Bit();
system(cmdArray.data());
}
}
bool runNodeJsServer() {
g_nodeJsServerProcess = new QProcess();
g_nodeJsServerProcess->setWorkingDirectory(getDataStoragePath());
g_nodeJsServerProcess->setProgram(QGuiApplication::applicationDirPath() + QDir::separator() + NODEJS_SERVER_NAME);
QString port = qgetenv("REACT_SERVER_PORT");
if (!port.isEmpty()) {
QStringList arguments = (QStringList() << "--port" << port);
g_nodeJsServerProcess->setArguments(arguments);
}
QObject::connect(g_nodeJsServerProcess, &QProcess::errorOccurred,
[=](QProcess::ProcessError) {
qCWarning(JSSERVER) << "process name: "
<< qUtf8Printable(g_nodeJsServerProcess->program());
qCWarning(JSSERVER) << "process error: "
<< qUtf8Printable(g_nodeJsServerProcess->errorString());
});
QObject::connect(
g_nodeJsServerProcess, &QProcess::readyReadStandardOutput, [=] {
writeLogFromJSServer(g_nodeJsServerProcess->readAllStandardOutput().trimmed());
});
QObject::connect(
g_nodeJsServerProcess, &QProcess::readyReadStandardError, [=] {
QString output =
g_nodeJsServerProcess->readAllStandardError().trimmed();
writeLogFromJSServer(output);
if (output.contains("Server starting")) {
nodeJsServerStarted = true;
}
});
QObject::connect(QGuiApplication::instance(), &QCoreApplication::aboutToQuit,
[=]() {
qCDebug(STATUS) << "Kill node.js server process";
g_nodeJsServerProcess->kill();
});
qCDebug(STATUS) << "starting node.js server process...";
g_nodeJsServerProcess->start();
qCDebug(STATUS) << "wait for started...";
if (g_nodeJsServerProcess->waitForReadyRead(10000)) {
// We know that the process started, now wait until it communicates that it has started
while (!nodeJsServerStarted) {
QGuiApplication::processEvents();
}
qCDebug(STATUS) << "waiting finished";
return true;
} else {
qCDebug(STATUS) << "failed to start process";
}
return false;
}
#endif
void writeLogFromJSServer(const QString &msg) {
if (msg.contains("\\n")) {
QStringList lines = msg.split("\\n");
foreach (const QString &line, lines) {
writeSingleLineLogFromJSServer(line);
}
} else {
writeSingleLineLogFromJSServer(msg);
}
}
QString extractJSServerMessage(const QString& msg, int prefixLength) {
return msg.mid(prefixLength);
}
void writeSingleLineLogFromJSServer(const QString &msg) {
if (msg.startsWith("TRACE "))
qCDebug(JSSERVER) << qUtf8Printable(extractJSServerMessage(msg, 6));
else if (msg.startsWith("DEBUG "))
qCDebug(JSSERVER) << qUtf8Printable(extractJSServerMessage(msg, 6));
else if (msg.startsWith("INFO "))
qCInfo(JSSERVER) << qUtf8Printable(extractJSServerMessage(msg, 5));
else if (msg.startsWith("WARN "))
qCWarning(JSSERVER) << qUtf8Printable(extractJSServerMessage(msg, 5));
else if (msg.startsWith("ERROR "))
qCWarning(JSSERVER) << qUtf8Printable(extractJSServerMessage(msg, 6));
else if (msg.startsWith("FATAL "))
qCCritical(JSSERVER) << qUtf8Printable(extractJSServerMessage(msg, 6));
else
qCDebug(JSSERVER) << qUtf8Printable(msg);
}
void appendConsoleString(const QString &msg) {
QMutexLocker locker(&consoleOutputMutex);
consoleOutputStrings << msg;
}
void saveMessage(QtMsgType type, const QMessageLogContext &context,
const QString &msg) {
Q_UNUSED(context);
QByteArray localMsg = msg.toLocal8Bit();
QString message = localMsg + "\n";
QString timestamp = QDateTime::currentDateTime().toString("hh:mm:ss.zzz");
QString typeStr;
switch (type) {
case QtDebugMsg:
typeStr = "D";
break;
case QtInfoMsg:
typeStr = "I";
break;
case QtWarningMsg:
typeStr = "W";
break;
case QtCriticalMsg:
typeStr = "C";
break;
case QtFatalMsg:
typeStr = "F";
}
appendConsoleString(QString("%1 - %2 - [%3] - %4").arg(timestamp, typeStr, context.category, message));
if (type == QtFatalMsg) {
writeLogsToFile();
abort();
}
}
#include "main.moc"
-27
View File
@@ -1,27 +0,0 @@
# Copyright (c) 2017-present, Status Research and Development GmbH.
# All rights reserved.
#
# This source code is licensed under the BSD-style license found in the
# LICENSE file in the root directory of this source tree. An additional grant
# of patent rights can be found in the PATENTS file in the same directory.
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTORCC ON)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(APP_NAME "reportApp")
set(MAIN_CPP_SOURCE reportpublisher.cpp
main.cpp)
add_executable(
${APP_NAME}
${MAIN_CPP_SOURCE}
main.qrc
)
set(USED_QT_MODULES Core Qml Quick WebSockets Widgets Svg)
qt5_use_modules(${APP_NAME} ${USED_QT_MODULES})
set(REACT_NATIVE_DESKTOP_EXTERNAL_PROJECT_DEPS ${REACT_NATIVE_DESKTOP_EXTERNAL_PROJECT_DEPS} reportApp PARENT_SCOPE)
-49
View File
@@ -1,49 +0,0 @@
/**
* Copyright (c) 2017-present, Status Research and Development GmbH.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
*/
#include <QDebug>
#include <QGuiApplication>
#include <QQmlContext>
#include <QQuickView>
#include "reportpublisher.h"
const int MAIN_WINDOW_WIDTH = 1024;
const int MAIN_WINDOW_HEIGHT = 768;
const int INPUT_ARGUMENTS_COUNT = 6;
const int MINIDUMP_FILE_PATH_ARG_INDEX = 1;
const int CRASHED_EXECUTABLE_PATH_ARG_INDEX = 2;
const int LOGS_PATH_INDEX = 5;
int main(int argc, char **argv) {
QGuiApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
QGuiApplication app(argc, argv);
if (argc != INPUT_ARGUMENTS_COUNT) {
return 1;
}
app.setApplicationName("Crash Report");
ReportPublisher reportPublisher(argv[MINIDUMP_FILE_PATH_ARG_INDEX],
argv[CRASHED_EXECUTABLE_PATH_ARG_INDEX],
argv[LOGS_PATH_INDEX]);
QQuickView view;
view.rootContext()->setContextProperty("reportPublisher", &reportPublisher);
view.setSource(QUrl("qrc:///main.qml"));
view.setResizeMode(QQuickView::SizeRootObjectToView);
view.resize(MAIN_WINDOW_WIDTH, MAIN_WINDOW_HEIGHT);
view.show();
return app.exec();
}
-77
View File
@@ -1,77 +0,0 @@
/**
* Copyright (c) 2017-present, Status Research and Development GmbH.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
*/
import QtQuick 2.4
import QtQuick.Controls 2.2
import QtQuick.Layouts 1.3
Rectangle {
id: root
width: 384
height: 640
ColumnLayout {
anchors.centerIn: parent
Text {
Layout.alignment: Qt.AlignCenter
text: "Oh, no! Status application just crashed!"
font.bold: true
font.pointSize: 25
}
Text {
Layout.alignment: Qt.AlignCenter
Layout.topMargin: 20
text: "Please report us <b>crash.dmp</b> and <b>Status</b> executable files to allow us fix the issue!"
font.bold: true
font.pointSize: 20
}
RowLayout {
Layout.alignment: Qt.AlignCenter
Layout.topMargin: 40
spacing: 25
Button {
Layout.minimumWidth: 150
text: "Report (highly appreciated)"
onClicked: reportPublisher.submit()
}
Button {
text: "Restart and Quit"
onClicked: reportPublisher.restartAndQuit()
}
Button {
text: "Just Quit"
onClicked: reportPublisher.quit()
}
}
RowLayout {
Layout.alignment: Qt.AlignCenter
Layout.topMargin: 100
TextEdit {
readOnly: true
Layout.maximumWidth: 500
wrapMode: TextEdit.Wrap
selectByMouse: true
font.pointSize: 12
textFormat: TextEdit.RichText
text: "<div>Please upload both <b>crash.dmp</b> and <b>Status</b> executable files from the report directory:<br>" + reportPublisher.resolveDataStoragePath() + "</div>"
}
Button {
text: "View"
onClicked: reportPublisher.showDirectory()
}
}
}
}
-5
View File
@@ -1,5 +0,0 @@
<RCC>
<qresource>
<file>main.qml</file>
</qresource>
</RCC>
-111
View File
@@ -1,111 +0,0 @@
/**
* Copyright (c) 2017-present, Status Research and Development GmbH.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
*/
#include "reportpublisher.h"
#include <QApplication>
#include <QDebug>
#include <QDesktopServices>
#include <QDir>
#include <QDirIterator>
#include <QFile>
#include <QProcess>
#include <QUrl>
const QString REPORT_SUBMIT_URL =
QStringLiteral("https://goo.gl/forms/0705ZN0EMW3xLDpI2");
ReportPublisher::ReportPublisher(QString minidumpFilePath,
QString crashedExecutablePath,
QString logsPath, QObject *parent)
: QObject(parent), m_minidumpFilePath(minidumpFilePath),
m_logsPath(logsPath), m_crashedExecutablePath(crashedExecutablePath) {}
void ReportPublisher::submit() {
QDesktopServices::openUrl(QUrl(REPORT_SUBMIT_URL));
showDirectory();
}
void ReportPublisher::restartAndQuit() {
QString appPath = m_crashedExecutablePath;
#if defined(Q_OS_MACOS) || defined(Q_OS_LINUX)
QFileInfo crashedExecutableFileInfo(m_crashedExecutablePath);
QString fullPath = crashedExecutableFileInfo.dir().absolutePath();
#ifdef Q_OS_MACOS
const QString bundleExtension = QStringLiteral(".app");
const QString cmdTemplate = QStringLiteral("open \"%1\"");
#else
const QString bundleExtension = QStringLiteral(".AppImage");
const QString cmdTemplate = QStringLiteral("\"%1\"");
#endif
if (fullPath.contains(bundleExtension)) {
appPath = fullPath.left(fullPath.indexOf(bundleExtension) +
bundleExtension.size());
}
QString cmd = QString(cmdTemplate).arg(appPath);
#else
QString cmd = QString("\"%1\"").arg(appPath);;
#endif
QProcess::startDetached(cmd);
qApp->quit();
}
void ReportPublisher::quit() { qApp->quit(); }
void ReportPublisher::showDirectory() {
QString dataStoragePath = resolveDataStoragePath();
if (!m_logFilesPrepared) {
m_logFilesPrepared = prepareReportFiles(dataStoragePath);
}
QDesktopServices::openUrl(QUrl::fromLocalFile(dataStoragePath));
}
bool ReportPublisher::prepareReportFiles(QString reportDirPath) {
QFileInfo minidumpFileInfo(m_minidumpFilePath);
QFileInfo crashedExecutableFileInfo(m_crashedExecutablePath);
if (!minidumpFileInfo.exists() || !crashedExecutableFileInfo.exists())
return false;
return QFile::copy(m_minidumpFilePath,
reportDirPath + QDir::separator() + "crash.dmp") &&
QFile::copy(m_crashedExecutablePath,
reportDirPath + QDir::separator() +
crashedExecutableFileInfo.fileName()) &&
prepareLogFiles(reportDirPath);
}
bool ReportPublisher::prepareLogFiles(QString reportDirPath) {
if (reportDirPath.isEmpty())
return true;
QDirIterator filesIterator(m_logsPath, QStringList() << "*.log", QDir::Files);
while (filesIterator.hasNext()) {
QFileInfo logFile(filesIterator.next());
QFile::copy(logFile.absoluteFilePath(),
reportDirPath + QDir::separator() + logFile.fileName());
}
return true;
}
QString ReportPublisher::resolveDataStoragePath() {
QFileInfo minidumpFileInfo(m_minidumpFilePath);
QString dataStoragePath =
QStandardPaths::writableLocation(QStandardPaths::AppLocalDataLocation) +
QDir::separator() + minidumpFileInfo.baseName();
QDir dir(dataStoragePath);
if (!dir.exists()) {
dir.mkpath(".");
}
return dir.path();
}
-40
View File
@@ -1,40 +0,0 @@
/**
* Copyright (c) 2017-present, Status Research and Development GmbH.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
*/
#ifndef REPORTPUBLISHER
#define REPORTPUBLISHER
#include <QObject>
#include <QString>
class ReportPublisher : public QObject {
Q_OBJECT
public:
ReportPublisher(QString minidumpFilePath, QString crashedExecutablePath,
QString logsPath, QObject *parent = 0);
Q_INVOKABLE void submit();
Q_INVOKABLE void restartAndQuit();
Q_INVOKABLE void quit();
Q_INVOKABLE void showDirectory();
Q_INVOKABLE QString resolveDataStoragePath();
private:
bool prepareReportFiles(QString reportDirPath);
bool prepareLogFiles(QString reportDirPath);
QString m_minidumpFilePath;
QString m_crashedExecutablePath;
QString m_logsPath;
bool m_logFilesPrepared = false;
};
#endif // REPORTPUBLISHER
Binary file not shown.

Before

Width:  |  Height:  |  Size: 132 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 317 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 142 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 155 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 145 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 167 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 127 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 308 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 431 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 350 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 386 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 281 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 141 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 190 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 260 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 229 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 526 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 614 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 613 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 537 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 274 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 307 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 176 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 208 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 150 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 139 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 296 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 132 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 325 B

Some files were not shown because too many files have changed in this diff Show More