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

Change Local SDCard Folder #105

Closed
shubhank008 opened this issue Mar 6, 2013 · 10 comments
Closed

Change Local SDCard Folder #105

shubhank008 opened this issue Mar 6, 2013 · 10 comments

Comments

@shubhank008
Copy link

I have been interested in owncloud since a few months specially due to its open source android app and that anyone can customize it according to their needs.

I am still new to java and programming but have been playing around with the app code to do bit by bit modifications to suit my personal needs.

I wanted to change the default owncloud folder location and folder name used by the app to learn more and suit my needs.
I have tried to analogize the code and a few java files related to file operations in "src" but wasnt unable to find any hint related to change the folder.

Can someone please point me to the file/part of code by which I can modify the name of the folder on localdisk on phone from "owncloud" to something like maybe "cloud" or "instant backup" etc. and secondly change it from / location to something like /folder/folder2/cloud

Any help will be appreciated

@davivel
Copy link
Contributor

davivel commented Mar 7, 2013

Hi there.

The name of the folder is one those things that still is in the worst possible place in code. Hardcoded in the class com.owncloud.androud.utils.FileStorageUtils.java .

Let's keep the issue open. This has bothered us recently an is very probable that we change the location in the short term. I will comment it here when done.

@shubhank008
Copy link
Author

OMG Super super super Thanks lol
I swear I checked almost all main looking files except that file and related utils :|
And Dumb Luck that the path and name is in topmost part of code itself.

I will now try to replace the folder name with dynamic string instead stored in strings.xml so that folder name can be easily updated via the xml file.

Also, just for information, would changing the path affect anything ?
Like changing
return sdCard.getAbsolutePath() + "/owncloud/"
to
return sdCard.getAbsolutePath() + "/cloud/sync/"

and so on changing /owncloud/ with /cloud/sync/ kind of


Also a bit offtopic, but can you tell me which file controls the popup code for About menu item ?
I wanted to add a code to display the Android OS's Ver. num and name below app version code but unable to find any related code or file at all.
Some help will be really appreciated

PS: Thanks again

@davivel
Copy link
Contributor

davivel commented Mar 7, 2013

In theory, you shold not break nothing with that change. That is the reason why the class FileStorageUtils was created, and that's why it is so dumb that we left the "ownCloud/" hardcoded there.


FileDisplayActivity.onCreateDialog() for the 'About' dialog.

@shubhank008
Copy link
Author

Oh great, really point to point help :D Now will try to implement that Android OS version details thing on About Screen

Have already done that dynamic storage path based on value on strings.xml so will test once my last customization for today is done

One last thing before I close this issue, while testing one of my friend reported this :

"since i am on jelly bean 4.1.2 it asks me to open Google play and download the app for my version from own cloud"

Is there any such thing that such a error occurs based on Android OS ? I am using the latest github source (2 days old)
If there is such a setting, can you point me where I can actually disable this message or simply replace it with something else like "OS not supported" kinda
I dont know why or how he got that as I have tested in 4.0 and it was working on phone and emulator and I didnt found any string for such error aswell

Regards

@davivel
Copy link
Contributor

davivel commented Mar 7, 2013

The error affects only to Android 4.1.x devices, as long as we now . So the warning is only shown when version is >= 4.1, that's why you don't see it. The code is in the method FileDisplayActivity#showChangleLog().

Anyway, better you forget about this warning dialog. We will remove it for next releases, we consider too annoying show a dialog on the first start after every release, since we want release often. In this case, this was a specially ugly and persistent problem, so we decided to include the warning just for this time.

Let me insist. With a 4.0 Android, you don't need the helper app at all.

And about the point to point help... better you don't get accustomed :( . It is not something our agenda let us do often. But don't you get discouraged with this, it is really great see people interested in learning and improving the app :)

@shubhank008
Copy link
Author

Lol dont worry I wont bug the team daily, I am just kinda new to android and java so getting used to it.
I was earlier thinking to try and make another type of version of android app which will actually will be a mobile frame browser window and will just directly browse and use the webUI in it.

Optimizing the Web Panel (making mobile version of it) would attract quite a handfull users to it as webUI has more control on files and stuff compared to the app. The only thing I liked was "Keep Upto Date" , instant upload and the progress bars for download/upload.
Lets see how far I get.

Anyways coming back to this topic, I am atm exporting the test .apk I have customized a bit to see how it works.
Fixed and made that Default WorkDir dynamic based on App Name
Added Android OS Details in About Dialog

Btw, these changelog and version popup things should be in a configurable style, even if its a True/False bool in strings.xml as that can help users customize more and saving the time.
I will try to disable it first and then try this bool thing
As waiting for a full update will be bit hectic for me as I forgot to take note of what customizations I am doing and where xD

Anyways, Thanks for all the help
You can close the issue and mark it as Solved after adding any further comment if you want to 📦 Else will do myself

@davivel
Copy link
Contributor

davivel commented Mar 7, 2013

I am happy to help. Have fun with your experiments, and come back when you want.

@davivel davivel closed this as completed Mar 7, 2013
@negativerad
Copy link

Did this ever get resolved? I am using the official owncloud android app, and I don't see how I can change the default location for saving data. It's going right to the sdcard, and I would prefer it be on the extSdcard.

@davivel
Copy link
Contributor

davivel commented Jul 23, 2014

I thing what you are interested is #10, that is not implemented yet. Sorry.

@negativerad
Copy link

Yes, Thank you!

davigonz pushed a commit that referenced this issue Feb 10, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants