{"id":18784493,"url":"https://github.com/pwittchen/touch","last_synced_at":"2025-08-24T14:14:29.330Z","repository":{"id":57722222,"uuid":"243849987","full_name":"pwittchen/touch","owner":"pwittchen","description":"Android library, which allows to monitor raw touch events on the screen of the device with RxJava","archived":false,"fork":false,"pushed_at":"2020-04-06T13:03:45.000Z","size":176,"stargazers_count":3,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"RxJava2.x","last_synced_at":"2025-05-21T09:11:24.828Z","etag":null,"topics":["android","rxjava","screen","touch","touchscreen"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pwittchen.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"github":["pwittchen"],"custom":["https://paypal.me/pwittchen"]}},"created_at":"2020-02-28T20:36:06.000Z","updated_at":"2023-11-25T16:35:27.000Z","dependencies_parsed_at":"2022-08-29T23:00:53.518Z","dependency_job_id":null,"html_url":"https://github.com/pwittchen/touch","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/pwittchen/touch","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pwittchen%2Ftouch","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pwittchen%2Ftouch/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pwittchen%2Ftouch/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pwittchen%2Ftouch/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pwittchen","download_url":"https://codeload.github.com/pwittchen/touch/tar.gz/refs/heads/RxJava2.x","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pwittchen%2Ftouch/sbom","scorecard":{"id":750822,"data":{"date":"2025-08-11","repo":{"name":"github.com/pwittchen/touch","commit":"1165780b866963d6306837bc1a9434133ae5850f"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.3,"checks":[{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Code-Review","score":0,"reason":"Found 0/23 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/android.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Binary-Artifacts","score":9,"reason":"binaries present in source code","details":["Warn: binary detected: gradle/wrapper/gradle-wrapper.jar:1"],"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/android.yml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/pwittchen/touch/android.yml/RxJava2.x?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/android.yml:19: update your workflow using https://app.stepsecurity.io/secureworkflow/pwittchen/touch/android.yml/RxJava2.x?enable=pin","Info:   0 out of   2 GitHub-owned GitHubAction dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: Apache License 2.0: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'RxJava2.x'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}}]},"last_synced_at":"2025-08-22T20:18:32.020Z","repository_id":57722222,"created_at":"2025-08-22T20:18:32.020Z","updated_at":"2025-08-22T20:18:32.020Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271884453,"owners_count":24838492,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-24T02:00:11.135Z","response_time":111,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["android","rxjava","screen","touch","touchscreen"],"created_at":"2024-11-07T20:43:11.088Z","updated_at":"2025-08-24T14:14:29.312Z","avatar_url":"https://github.com/pwittchen.png","language":"Java","funding_links":["https://github.com/sponsors/pwittchen","https://paypal.me/pwittchen"],"categories":[],"sub_categories":[],"readme":"# touch\nAndroid library, which allows to monitor raw touch events on the screen of the device with RxJava\n\n Current Branch | Branch  | Artifact Id  | Maven Central | CI build |\n|:--------------:|:-------:|:-----------:|:-------------:|:--------:|\n| :ballot_box_with_check: | [`RxJava2.x`](https://github.com/pwittchen/touch/tree/RxJava2.x) | `touch-rx2` | ![Maven Central](https://img.shields.io/maven-central/v/com.github.pwittchen/touch-rx2.svg?style=flat-square) | ![Android CI](https://github.com/pwittchen/touch/workflows/Android%20CI/badge.svg?branch=RxJava2.x) |\n\nContents\n--------\n- [Usage](#usage)\n- [Example](#example)\n- [Download](#download)\n- [Tests](#tests)\n- [Code style](#code-style)\n- [Static code analysis](#static-code-analysis)\n- [Release](#release)\n- [References](#references)\n- [License](#license)\n\nUsage\n-----\n\n**Step 1**: Create `Touch` attribute and `Disposable` in the `Activity`:\n\n```java\nprivate Touch touch;\nprivate Disposable disposable;\n```\n\n**Step 2**: Initialize `Touch` object and subscribe `Flowable`:\n\n```java\n@Override protected void onCreate(Bundle savedInstanceState) {\n  super.onCreate(savedInstanceState);\n  setContentView(R.layout.activity_main);\n  info = (TextView) findViewById(R.id.info);\n\n  touch = new Touch();\n\n  disposable = touch.observe()\n      .subscribeOn(Schedulers.computation())\n      .observeOn(AndroidSchedulers.mainThread())\n      .subscribe(touchEvent -\u003e info.setText(touchEvent.toString()));\n}\n```\n\n`TouchEvent` is a class with the following values:\n\n```java\npublic enum TouchEvent {\n  public float x() {}\n  public float y() {}\n  public TouchType type() {}\n}\n```\n\n`TouchType` is an enum with the following values:\n\n```java\npublic enum TouchType {\n  UP, DOWN, MOVE\n}\n```\n\n**Step 3**: override `dispatchTouchEvent(MotionEvent event)`:\n\n```java\n@Override public boolean dispatchTouchEvent(MotionEvent event) {\n  touch.dispatchTouchEvent(event);\n  return super.dispatchTouchEvent(event);\n}\n```\n\n**Step 4**: dispose previously created `Disposable` when it's no longer needed:\n\n```java\n@Override protected void onPause() {\n  super.onPause();\n  if (disposable != null \u0026\u0026 !disposable.isDisposed()) {\n    disposable.dispose();\n  }\n}\n```\n\nExample\n-------\n\nExemplary application is located in `app` directory of this repository.\n\nDownload\n--------\n\nlatest version: ![Maven Central](https://img.shields.io/maven-central/v/com.github.pwittchen/touch-rx2.svg?style=flat-square)\n\nreplace `x.y.z` with the latest version of the library\n\nYou can depend on the library through Maven:\n\n```xml\n\u003cdependency\u003e\n    \u003cgroupId\u003ecom.github.pwittchen\u003c/groupId\u003e\n    \u003cartifactId\u003etouch-rx2\u003c/artifactId\u003e\n    \u003cversion\u003ex.y.z\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\nor through Gradle:\n\n```groovy\ndependencies {\n  compile 'com.github.pwittchen:touch-rx2:x.y.z'\n}\n```\n\nTests\n-----\n\nTo execute unit tests run:\n\n```\n./gradlew test\n```\n\nCode style\n----------\n\nCode style used in the project is called `SquareAndroid` from Java Code Styles repository by Square available at: https://github.com/square/java-code-styles.\n\nStatic code analysis\n--------------------\n\nStatic code analysis runs Checkstyle, PMD and Lint. It can be executed with command:\n\n ```\n ./gradlew check\n ```\n\nReports from analysis are generated in `library/build/reports/` directory.\n\nRelease\n-------\n\nTo release the library, bump its version and call the following command:\n\n```\n./gradlew uploadArchives closeAndReleaseRepository\n```\n\nReferences\n----------\n\n- [better gesture detector project](https://github.com/Polidea/better-gesture-detector)\n- [gesture project](https://github.com/pwittchen/gesture)\n- [swipe project](https://github.com/pwittchen/swipe)\n- [detecting swipe gesture in mobile application](http://wittchen.io/detecting-swipe-gesture-in-mobile-application/)\n- [dispatchTouchEvent(event) method in documentation](http://developer.android.com/reference/android/view/ViewGroup.html#dispatchTouchEvent(android.view.MotionEvent))\n- [MotionEvent class in documentation](http://developer.android.com/reference/android/view/MotionEvent.html)\n\nLicense\n-------\n\n    Copyright 2020 Piotr Wittchen\n\n    Licensed under the Apache License, Version 2.0 (the \"License\");\n    you may not use this file except in compliance with the License.\n    You may obtain a copy of the License at\n\n       http://www.apache.org/licenses/LICENSE-2.0\n\n    Unless required by applicable law or agreed to in writing, software\n    distributed under the License is distributed on an \"AS IS\" BASIS,\n    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n    See the License for the specific language governing permissions and\n    limitations under the License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpwittchen%2Ftouch","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpwittchen%2Ftouch","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpwittchen%2Ftouch/lists"}