From 80dc0167cf9fb91cd9373bdd2a93793f71b901dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Parm=C3=A9nides=20GV?= Date: Thu, 15 May 2014 17:41:41 +0200 Subject: Copy some necessary icons from ics-openvpn. I'm hardcoding their values based on the compilation errors (i.e., the drawables referenced by de.blinkt.openvpn.core.OpenVpnService). If a new drawable were introduced, build.gradle should be updated accordingly. --- build.gradle | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'build.gradle') diff --git a/build.gradle b/build.gradle index 76d60d0b..29ceb2f2 100644 --- a/build.gradle +++ b/build.gradle @@ -51,9 +51,16 @@ task copyIcsOpenVPNClasses( type: Copy ) { } filter { line -> line.replaceAll('de.blinkt.openvpn.BuildConfig', 'se.leap.bitmaskclient.BuildConfig') - } - } - into 'app' + } + } into 'app' + + from ('ics-openvpn/main') { + //TODO We should detect which drawables are needed by the classes + //we need (such as de.blinkt.openvpn.core.OpenVpnService) + include '**/ic_stat_vpn_offline.png' + include '**/ic_stat_vpn_outline.png' + include '**/ic_stat_vpn_empty_halo.png' + } into 'app' } def processFileInplace(file, Closure processText) { @@ -62,7 +69,7 @@ def processFileInplace(file, Closure processText) { } // thanks to http://pleac.sourceforge.net/pleac_groovy/fileaccess.html -task removeDuplicatedStrings() << { +task removeDuplicatedStrings( dependsOn: 'copyIcsOpenVPNClasses' ) { def resources_directory = new File('./app/src/main/res/') resources_directory.eachFileRecurse { if(it.name.equals('strings.xml')) { -- cgit v1.2.3