This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.statist.grap; | |
| import java.io.BufferedReader; | |
| import java.io.File; | |
| import java.io.FileNotFoundException; | |
| import java.io.IOException; | |
| import java.io.InputStream; | |
| import java.io.InputStreamReader; | |
| import java.io.OutputStreamWriter; | |
| import java.util.ArrayList; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| private void sendInfoToServer(int serverId) { | |
| sendCount = 0; | |
| final File logFile = new File(Environment.getExternalStorageDirectory(), "/temp/statist/logs.txt"); | |
| if (!logFile.exists()) | |
| return; | |
| final JSONArray jsonToSendArray = new JSONArray(); | |
| try { | |
| FileInputStream inputStream = new FileInputStream(Environment.getExternalStorageDirectory().getAbsolutePath() + "/temp/statist/logs.txt"); | |
| if (inputStream != null) { | |
| InputStreamReader inputStreamReader = new InputStreamReader(inputStream); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <? | |
| class StatController extends Controller | |
| { | |
| public $layout = '//layouts/clear'; | |
| public function actionIndex() | |
| { | |
| $ids = array(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| val myIntent = Intent(this, TimerReceiver::class.java) | |
| val alarmManager = getSystemService(ALARM_SERVICE) as AlarmManager | |
| val pendingIntent = PendingIntent.getService(this, 0, myIntent, PendingIntent.FLAG_UPDATE_CURRENT) | |
| val calendar = Calendar.getInstance() | |
| calendar.set(Calendar.HOUR_OF_DAY, 23) | |
| calendar.set(Calendar.MINUTE, 29) | |
| calendar.set(Calendar.SECOND, 0) | |
| alarmManager.setRepeating(AlarmManager.RTC_WAKEUP, System.currentTimeMillis(), 48 * 60 * 60 * 1000, pendingIntent) //set repeating every 24 hours |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| buildscript { | |
| repositories { | |
| maven { url 'https://maven.fabric.io/public' } | |
| } | |
| dependencies { | |
| classpath 'io.fabric.tools:gradle:1.24.3' | |
| } | |
| } | |
| apply plugin: 'com.android.application' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| buildscript { | |
| repositories { | |
| maven { url 'https://maven.fabric.io/public' } | |
| } | |
| dependencies { | |
| classpath 'io.fabric.tools:gradle:1.24.3' | |
| } | |
| } | |
| apply plugin: 'com.android.application' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 10-18 16:30:36.502 4333-4333/com.nokl.androidclient E/AndroidRuntime: FATAL EXCEPTION: main | |
| Process: com.nokl.androidclient, PID: 4333 | |
| java.lang.NullPointerException: Attempt to invoke virtual method 'void com.nokl.androidclient.credential.login.LPresenter.ok()' on a null object reference | |
| at com.nokl.androidclient.credential.login.LoginFragment.onCreateView(LoginFragment.java:104) | |
| at android.support.v4.app.Fragment.performCreateView(Fragment.java:2192) | |
| at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1299) | |
| at android.support.v4.app.FragmentManagerImpl.moveFragmentToExpectedState(FragmentManager.java:1528) | |
| at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1595) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class FirstRunWizardFragment extends NoklFragment { | |
| public static final String TAG = "com.nokl.androidclient.firstrunwizard"; | |
| public static FirstRunWizardFragment newInstance() { | |
| return new FirstRunWizardFragment(); | |
| } | |
| @Nullable | |
| @Override | |
| public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| override fun onActivityCreated(savedInstanceState: Bundle?) { | |
| super.onActivityCreated(savedInstanceState) | |
| UiUtils.hideKeyboard(activity!!) | |
| fab.setOnClickListener { | |
| presenter.myLocationButtonClicked() | |
| } | |
| city_name.setOnClickListener { | |
| presenter.citySearchClicked() | |
| } | |
| map_view.onCreate(savedInstanceState) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| override func viewDidLoad() { | |
| super.viewDidLoad() | |
| // Do any additional setup after loading the view, typically from a nib. | |
| let searchController = UISearchController(searchResultsController: nil) | |
| UITextField.appearance(whenContainedInInstancesOf: [UISearchBar.self]).defaultTextAttributes = [NSAttributedStringKey.foregroundColor.rawValue: UIColor.white] | |
| if let textfield = searchController.searchBar.value(forKey: "searchField") as? UITextField { | |
| //let ss = sw?.subviews | |
| if let backgroundview = textfield.subviews.first { |