Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(android)(9_3_X): removed unneeded libraries #11970

Merged
merged 3 commits into from Sep 28, 2020

Conversation

jquick-axway
Copy link
Contributor

JIRA:

Summary:

  • Removed Apache "common-logging" library.
    • We were not using this library at all. (Perhaps many years ago we used to.)
  • Removed "nineoldandroids" library.
    • Was used to implement animations on Android 2.3 and older.
    • Switched to using Android OS built-in animation classes.

Test:

  1. Create a "Classic" Titanium app project.
  2. Add the below "build.gradle" file to project folder: ./platform/android
  3. Copy the below "app.js" code.
  4. Build and run on Android.
  5. Verify it builds successfully. (This tests TIMOB-28081.)
  6. Verify you see a blue square with a black border scale in/out on-screen.

./platform/android/build.gradle

dependencies {
	implementation 'commons-logging:commons-logging:1.1.3'
}

./Resources/app.js

var window = Ti.UI.createWindow({
	backgroundColor: "white",
	fullscreen: true,
});
var squareView = Ti.UI.createView({
	backgroundColor: "blue",
	borderColor: "black",
	borderWidth: "2dp",
	width: "80dp",
	height: "80dp",
});
window.add(squareView);
window.addEventListener("postlayout", function onLayout() {
	window.removeEventListener("postlayout", onLayout);
	var windowSize = window.size;
	var minDimension = Math.min(windowSize.width, windowSize.height);
	var letterboxScale = minDimension / squareView.size.width;
	var animation = Ti.UI.createAnimation({
		transform: Ti.UI.createMatrix2D().scale(letterboxScale, letterboxScale),
		duration: 2000,
		autoreverse: true,
		repeat: 1000,
	});
	squareView.animate(animation);
});
window.open();

- Removed "common-logging" library.
- Removed "nineoldandroids" library.
  * Only needed by Android 2.3 and older, which we no longer support.

Fixes TIMOB-27873, TIMOB-28081
@build
Copy link
Contributor

build commented Aug 27, 2020

Messages
📖 👍 Hey!, You deleted more code than you added. That's awesome!
📖 ✊ The commits in this PR match our conventions! Feel free to Rebase and Merge this PR when ready.
📖

✅ All tests are passing
Nice one! All 2520 tests are passing.
(There are 239 skipped tests not included in that total)

Generated by 🚫 dangerJS against dd58fa1

Copy link
Contributor

@garymathews garymathews left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CR: PASS

@jquick-axway jquick-axway added the backport master when applied, PRs with this label will get an auto-generated backport to master branch on merge label Sep 21, 2020
@ssjsamir ssjsamir self-requested a review September 28, 2020 14:23
Copy link
Contributor

@ssjsamir ssjsamir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FR Passed, Able to see a blue square with a black border scale in/out on-screen. Tested using the example provided in the description.

Test Environment

MacOS Big Sur: 11.0 Beta 7
Xcode: 12.0 
Java Version: 1.8.0_242
Android NDK: 21.3.6528147
Node.js: 12.18.1
""NPM":"5.0.0","CLI":"8.1.1""
Pixel XL (10.0)

@sgtcoolguy sgtcoolguy merged commit 6d84fc0 into tidev:9_3_X Sep 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
android backport master when applied, PRs with this label will get an auto-generated backport to master branch on merge improvement in-qe-testing 🕵 no tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants