mirror of
https://github.com/Kunzisoft/KeePassDX.git
synced 2025-12-04 15:49:33 +01:00
Refactor packages
This commit is contained in:
@@ -135,9 +135,9 @@
|
||||
android:configChanges="orientation|keyboardHidden" />
|
||||
<activity android:name="com.keepassdroid.settings.SettingsAutofillActivity" />
|
||||
|
||||
<service android:name="com.keepassdroid.services.TimeoutService" />
|
||||
<service android:name="com.keepassdroid.timeout.TimeoutService" />
|
||||
<service
|
||||
android:name="com.keepassdroid.services.NotificationCopyingService"
|
||||
android:name="com.keepassdroid.notifications.NotificationCopyingService"
|
||||
android:enabled="true"
|
||||
android:exported="false" />
|
||||
<service
|
||||
|
||||
@@ -40,7 +40,7 @@ import com.keepassdroid.database.Database;
|
||||
import com.keepassdroid.database.PwDatabase;
|
||||
import com.keepassdroid.database.PwEntry;
|
||||
import com.keepassdroid.password.PasswordActivity;
|
||||
import com.keepassdroid.services.NotificationCopyingService;
|
||||
import com.keepassdroid.notifications.NotificationCopyingService;
|
||||
import com.keepassdroid.settings.PreferencesUtil;
|
||||
import com.keepassdroid.timeout.ClipboardHelper;
|
||||
import com.keepassdroid.utils.EmptyUtils;
|
||||
|
||||
@@ -50,8 +50,8 @@ import com.keepassdroid.database.edit.OnFinish;
|
||||
import com.keepassdroid.database.edit.RunnableOnFinish;
|
||||
import com.keepassdroid.database.edit.UpdateEntry;
|
||||
import com.keepassdroid.database.security.ProtectedString;
|
||||
import com.keepassdroid.fragments.GeneratePasswordDialogFragment;
|
||||
import com.keepassdroid.fragments.IconPickerDialogFragment;
|
||||
import com.keepassdroid.dialogs.GeneratePasswordDialogFragment;
|
||||
import com.keepassdroid.dialogs.IconPickerDialogFragment;
|
||||
import com.keepassdroid.icons.Icons;
|
||||
import com.keepassdroid.settings.PreferencesUtil;
|
||||
import com.keepassdroid.tasks.ProgressTask;
|
||||
|
||||
@@ -54,10 +54,10 @@ import com.keepassdroid.database.SortNodeEnum;
|
||||
import com.keepassdroid.database.edit.AddGroup;
|
||||
import com.keepassdroid.database.edit.DeleteEntry;
|
||||
import com.keepassdroid.database.edit.DeleteGroup;
|
||||
import com.keepassdroid.dialog.ReadOnlyDialog;
|
||||
import com.keepassdroid.fragments.AssignMasterKeyDialogFragment;
|
||||
import com.keepassdroid.fragments.GroupEditDialogFragment;
|
||||
import com.keepassdroid.fragments.IconPickerDialogFragment;
|
||||
import com.keepassdroid.dialogs.ReadOnlyDialog;
|
||||
import com.keepassdroid.dialogs.AssignMasterKeyDialogFragment;
|
||||
import com.keepassdroid.dialogs.GroupEditDialogFragment;
|
||||
import com.keepassdroid.dialogs.IconPickerDialogFragment;
|
||||
import com.keepassdroid.password.PasswordActivity;
|
||||
import com.keepassdroid.search.SearchResultsActivity;
|
||||
import com.keepassdroid.tasks.ProgressTask;
|
||||
|
||||
@@ -46,13 +46,13 @@ import com.keepassdroid.database.PwGroup;
|
||||
import com.keepassdroid.database.PwNode;
|
||||
import com.keepassdroid.database.edit.AfterAddNodeOnFinish;
|
||||
import com.keepassdroid.database.edit.OnFinish;
|
||||
import com.keepassdroid.fragments.AssignMasterKeyDialogFragment;
|
||||
import com.keepassdroid.fragments.SortDialogFragment;
|
||||
import com.keepassdroid.dialogs.AssignMasterKeyDialogFragment;
|
||||
import com.keepassdroid.dialogs.SortDialogFragment;
|
||||
import com.keepassdroid.settings.PreferencesUtil;
|
||||
import com.keepassdroid.tasks.UIToastTask;
|
||||
import com.keepassdroid.utils.MenuUtil;
|
||||
import com.keepassdroid.database.SortNodeEnum;
|
||||
import com.keepassdroid.view.AssignPasswordHelper;
|
||||
import com.keepassdroid.password.AssignPasswordHelper;
|
||||
import com.kunzisoft.keepass.R;
|
||||
|
||||
public abstract class ListNodesActivity extends LockingActivity
|
||||
|
||||
@@ -26,7 +26,7 @@ import android.net.Uri;
|
||||
import com.keepassdroid.database.Database;
|
||||
import com.keepassdroid.database.PwDatabase;
|
||||
import com.keepassdroid.database.exception.InvalidKeyFileException;
|
||||
import com.keepassdroid.dialog.PasswordEncodingDialogHelper;
|
||||
import com.keepassdroid.dialogs.PasswordEncodingDialogHelper;
|
||||
import com.keepassdroid.utils.UriUtil;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.fragments;
|
||||
package com.keepassdroid.dialogs;
|
||||
|
||||
import android.app.Dialog;
|
||||
import android.content.Context;
|
||||
@@ -39,7 +39,7 @@ import android.widget.Toast;
|
||||
|
||||
import com.keepassdroid.utils.EmptyUtils;
|
||||
import com.keepassdroid.utils.UriUtil;
|
||||
import com.keepassdroid.view.KeyFileHelper;
|
||||
import com.keepassdroid.fileselect.KeyFileHelper;
|
||||
import com.kunzisoft.keepass.R;
|
||||
|
||||
public class AssignMasterKeyDialogFragment extends DialogFragment {
|
||||
@@ -17,7 +17,7 @@
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.fragments;
|
||||
package com.keepassdroid.dialogs;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.app.Dialog;
|
||||
@@ -17,7 +17,7 @@
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.fragments;
|
||||
package com.keepassdroid.dialogs;
|
||||
|
||||
import android.app.Dialog;
|
||||
import android.content.Context;
|
||||
@@ -17,7 +17,7 @@
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.fragments;
|
||||
package com.keepassdroid.dialogs;
|
||||
|
||||
import android.app.Dialog;
|
||||
import android.content.Context;
|
||||
@@ -17,7 +17,7 @@
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.fragments;
|
||||
package com.keepassdroid.dialogs;
|
||||
|
||||
import android.app.Dialog;
|
||||
import android.content.Context;
|
||||
@@ -17,7 +17,7 @@
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.dialog;
|
||||
package com.keepassdroid.dialogs;
|
||||
|
||||
import android.app.AlertDialog;
|
||||
import android.content.Context;
|
||||
@@ -17,7 +17,7 @@
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.dialog;
|
||||
package com.keepassdroid.dialogs;
|
||||
|
||||
import android.content.Context;
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.fragments;
|
||||
package com.keepassdroid.dialogs;
|
||||
|
||||
import android.app.Dialog;
|
||||
import android.content.Context;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.keepassdroid.fragments;
|
||||
package com.keepassdroid.dialogs;
|
||||
|
||||
import android.app.Dialog;
|
||||
import android.content.DialogInterface;
|
||||
@@ -17,7 +17,7 @@
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.dialog;
|
||||
package com.keepassdroid.dialogs;
|
||||
|
||||
import android.app.AlertDialog;
|
||||
import android.content.Context;
|
||||
@@ -49,17 +49,16 @@ import com.keepassdroid.autofill.AutofillHelper;
|
||||
import com.keepassdroid.database.edit.CreateDB;
|
||||
import com.keepassdroid.database.edit.FileOnFinish;
|
||||
import com.keepassdroid.database.exception.ContentFileNotFoundException;
|
||||
import com.keepassdroid.fragments.AssignMasterKeyDialogFragment;
|
||||
import com.keepassdroid.fragments.CreateFileDialogFragment;
|
||||
import com.keepassdroid.dialogs.AssignMasterKeyDialogFragment;
|
||||
import com.keepassdroid.dialogs.CreateFileDialogFragment;
|
||||
import com.keepassdroid.password.PasswordActivity;
|
||||
import com.keepassdroid.stylish.StylishActivity;
|
||||
import com.keepassdroid.tasks.ProgressTask;
|
||||
import com.keepassdroid.utils.EmptyUtils;
|
||||
import com.keepassdroid.utils.MenuUtil;
|
||||
import com.keepassdroid.utils.UriUtil;
|
||||
import com.keepassdroid.view.AssignPasswordHelper;
|
||||
import com.keepassdroid.password.AssignPasswordHelper;
|
||||
import com.keepassdroid.view.FileNameView;
|
||||
import com.keepassdroid.view.KeyFileHelper;
|
||||
import com.kunzisoft.keepass.R;
|
||||
|
||||
import java.io.File;
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.view;
|
||||
package com.keepassdroid.fileselect;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.content.ContentResolver;
|
||||
@@ -17,7 +17,7 @@
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.view;
|
||||
package com.keepassdroid.fingerprint;
|
||||
|
||||
import android.app.Dialog;
|
||||
import android.content.DialogInterface;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.keepassdroid.services;
|
||||
package com.keepassdroid.notifications;
|
||||
|
||||
import android.app.Notification;
|
||||
import android.app.NotificationChannel;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.keepassdroid.view;
|
||||
package com.keepassdroid.password;
|
||||
|
||||
|
||||
import android.content.Context;
|
||||
@@ -60,7 +60,7 @@ import com.keepassdroid.compat.EditorCompat;
|
||||
import com.keepassdroid.database.Database;
|
||||
import com.keepassdroid.database.edit.LoadDB;
|
||||
import com.keepassdroid.database.edit.OnFinish;
|
||||
import com.keepassdroid.dialog.PasswordEncodingDialogHelper;
|
||||
import com.keepassdroid.dialogs.PasswordEncodingDialogHelper;
|
||||
import com.keepassdroid.fingerprint.FingerPrintAnimatedVector;
|
||||
import com.keepassdroid.fingerprint.FingerPrintHelper;
|
||||
import com.keepassdroid.settings.PreferencesUtil;
|
||||
@@ -69,8 +69,8 @@ import com.keepassdroid.tasks.ProgressTask;
|
||||
import com.keepassdroid.utils.EmptyUtils;
|
||||
import com.keepassdroid.utils.MenuUtil;
|
||||
import com.keepassdroid.utils.UriUtil;
|
||||
import com.keepassdroid.view.FingerPrintDialog;
|
||||
import com.keepassdroid.view.KeyFileHelper;
|
||||
import com.keepassdroid.fingerprint.FingerPrintDialog;
|
||||
import com.keepassdroid.fileselect.KeyFileHelper;
|
||||
import com.kunzisoft.keepass.R;
|
||||
|
||||
import java.io.File;
|
||||
|
||||
@@ -40,7 +40,7 @@ import android.view.autofill.AutofillManager;
|
||||
import android.widget.Toast;
|
||||
|
||||
import com.keepassdroid.database.Database;
|
||||
import com.keepassdroid.fragments.UnavailableFeatureDialogFragment;
|
||||
import com.keepassdroid.dialogs.UnavailableFeatureDialogFragment;
|
||||
import com.keepassdroid.app.App;
|
||||
import com.keepassdroid.database.PwEncryptionAlgorithm;
|
||||
import com.keepassdroid.fingerprint.FingerPrintHelper;
|
||||
|
||||
@@ -8,7 +8,6 @@ import android.content.SharedPreferences;
|
||||
import android.preference.PreferenceManager;
|
||||
import android.util.Log;
|
||||
|
||||
import com.keepassdroid.services.TimeoutService;
|
||||
import com.kunzisoft.keepass.R;
|
||||
|
||||
public class Timeout {
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.services;
|
||||
package com.keepassdroid.timeout;
|
||||
|
||||
import android.app.NotificationManager;
|
||||
import android.app.Service;
|
||||
@@ -30,7 +30,6 @@ import android.os.IBinder;
|
||||
import android.util.Log;
|
||||
|
||||
import com.keepassdroid.app.App;
|
||||
import com.keepassdroid.timeout.Timeout;
|
||||
|
||||
public class TimeoutService extends Service {
|
||||
private static final String TAG = "KeePassDroid Timer";
|
||||
@@ -1,44 +0,0 @@
|
||||
/*
|
||||
* Copyright 2017 Brian Pellin, Jeremy Jamet / Kunzisoft.
|
||||
*
|
||||
* This file is part of KeePass DX.
|
||||
*
|
||||
* KeePass DX is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* KeePass DX is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.view;
|
||||
|
||||
import android.content.Context;
|
||||
import android.view.ContextMenu;
|
||||
import android.view.ContextMenu.ContextMenuInfo;
|
||||
import android.view.MenuItem;
|
||||
import android.widget.LinearLayout;
|
||||
|
||||
import com.keepassdroid.app.App;
|
||||
|
||||
public abstract class ClickView extends LinearLayout {
|
||||
protected boolean readOnly = false;
|
||||
|
||||
public ClickView(Context context) {
|
||||
super(context);
|
||||
|
||||
readOnly = App.getDB().readOnly;
|
||||
}
|
||||
|
||||
abstract public void onClick();
|
||||
|
||||
abstract public void onCreateMenu(ContextMenu menu, ContextMenuInfo menuInfo);
|
||||
|
||||
abstract public boolean onContextItemSelected(MenuItem item);
|
||||
}
|
||||
@@ -1,48 +0,0 @@
|
||||
/*
|
||||
* Copyright 2017 Brian Pellin, Jeremy Jamet / Kunzisoft.
|
||||
*
|
||||
* This file is part of KeePass DX.
|
||||
*
|
||||
* KeePass DX is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* KeePass DX is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.view;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.AttributeSet;
|
||||
import android.view.View;
|
||||
import android.widget.ScrollView;
|
||||
|
||||
public class NoFocusScrollView extends ScrollView {
|
||||
|
||||
public NoFocusScrollView(Context context, AttributeSet attrs, int defStyle) {
|
||||
super(context, attrs, defStyle);
|
||||
}
|
||||
|
||||
public NoFocusScrollView(Context context, AttributeSet attrs) {
|
||||
super(context, attrs);
|
||||
}
|
||||
|
||||
public NoFocusScrollView(Context context) {
|
||||
super(context);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ArrayList<View> getFocusables(int direction) {
|
||||
return new ArrayList<View>();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,61 +0,0 @@
|
||||
/*
|
||||
* Copyright 2017 Brian Pellin, Jeremy Jamet / Kunzisoft.
|
||||
*
|
||||
* This file is part of KeePass DX.
|
||||
*
|
||||
* KeePass DX is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* KeePass DX is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with KeePass DX. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
package com.keepassdroid.view;
|
||||
|
||||
import android.content.Context;
|
||||
import android.text.method.ArrowKeyMovementMethod;
|
||||
import android.text.method.MovementMethod;
|
||||
import android.util.AttributeSet;
|
||||
import android.widget.TextView;
|
||||
|
||||
public class TextViewSelect extends TextView {
|
||||
|
||||
public TextViewSelect(Context context) {
|
||||
this(context, null);
|
||||
}
|
||||
|
||||
public TextViewSelect(Context context, AttributeSet attrs) {
|
||||
this(context, attrs, android.R.attr.textViewStyle);
|
||||
}
|
||||
|
||||
public TextViewSelect(Context context, AttributeSet attrs, int defStyle) {
|
||||
super(context, attrs, defStyle);
|
||||
|
||||
setFocusable(true);
|
||||
setFocusableInTouchMode(true);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected MovementMethod getDefaultMovementMethod() {
|
||||
return ArrowKeyMovementMethod.getInstance();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean getDefaultEditable() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setText(CharSequence text, BufferType type) {
|
||||
super.setText(text, BufferType.EDITABLE);
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user