davinci: fod: Improve semantics

* do not use (void) to silence unused parameters
 * do not specify namespace for IFingerprintInscreenCallback

Change-Id: Ife9d0799a091c539028f775a728d2c8c31ffbf98
This commit is contained in:
Demon000 2019-12-31 01:06:45 +01:00 committed by Arian
parent c89dcfb0df
commit e456f36fe1
No known key found for this signature in database
GPG Key ID: 48029380598CE3B9
2 changed files with 3 additions and 6 deletions

View File

@ -126,7 +126,7 @@ Return<void> FingerprintInscreen::setLongPressEnabled(bool) {
return Void();
}
Return<int32_t> FingerprintInscreen::getDimAmount(int32_t brightness) {
Return<int32_t> FingerprintInscreen::getDimAmount(int32_t /* brightness */) {
int realBrightness = get(BRIGHTNESS_PATH, 0);
float alpha;
@ -136,8 +136,6 @@ Return<int32_t> FingerprintInscreen::getDimAmount(int32_t brightness) {
alpha = 1.0 - pow(realBrightness / 1680.0, 0.455);
}
(void) brightness;
return 255 * alpha;
}
@ -145,8 +143,7 @@ Return<bool> FingerprintInscreen::shouldBoostBrightness() {
return false;
}
Return<void> FingerprintInscreen::setCallback(const sp<::vendor::lineage::biometrics::fingerprint::inscreen::V1_0::IFingerprintInscreenCallback>& callback) {
(void) callback;
Return<void> FingerprintInscreen::setCallback(const sp<IFingerprintInscreenCallback>& /* callback */) {
return Void();
}

View File

@ -50,7 +50,7 @@ public:
Return<void> setLongPressEnabled(bool enabled) override;
Return<int32_t> getDimAmount(int32_t brightness) override;
Return<bool> shouldBoostBrightness() override;
Return<void> setCallback(const sp<::vendor::lineage::biometrics::fingerprint::inscreen::V1_0::IFingerprintInscreenCallback>& callback) override;
Return<void> setCallback(const sp<IFingerprintInscreenCallback>& callback) override;
private:
sp<IXiaomiFingerprint> xiaomiFingerprintService;