Categories
Development London Bus Pal

Connecting to the cloud

I have some grand ideas which need users to be less anonymous than they are now. People need the ability to sign into the app in order to do certain things (I don’t want to give away too much, but it will be personalised to them) – but some things needs them to be identified, especially if they use multiple devices.

Not being able to log in so far has always been fine and it makes things like GDPR compliance a whole lot easier. There are some difficulties however and I have had those suggestions made: being able to transfer settings from one phone to another for example.

So currently the idea is fairly simple – give users the ability to sign into the app and then they will be able to backup their favourites to the cloud and restore them when they wish. Of course, this can be more seamless than described here, but that’s the first pass at connecting the app into the cloud.

As it stands, I have built functionality to allow signing in with Google and Facebook details, as well as signing up for an account with username and password combinations. This all works and I just needs to make sure that everything is also fully GDPR compliant. (This is not yet in version 4.5.0 which is published at the time of writing, but it will probably be in the next version, unless I decide to do some quick bug fixes).

After doing the log in screen, the first bit of functionality I will enable is a simple “backup to cloud” and “restore from cloud” facility. This should make it loads easier for people to continue to use the app on different devices.

I am hoping for the functionality to connect to the app to the cloud to be released in September…

Categories
Development London Bus Pal

Reordering favourites

Today was spent finally implementing something I have been meaning to do for probably years now. Up until now, there just wasn’t a way to reorder your favourites – probably the only control you could have would be to add them in exactly the right order.

I kept flip-flopping between doing it directly on the favourites screen, or doing it in the settings screen. My opinion is that it would feel more natural to just take a stop on the main screen and drag it to the position you want it to be. That is, until you realise that some users have 10 or 20 favourites. It would be very difficult to organise it – especially if you want to drag something all the way from the one end to the other.

One other thing I have to think about was the potential of breaking the favourites screen to add this. You wouldn’t want to re-order favourites all the time. So I settled for the idea to do it in the settings screen. It also gave me the chance to quickly reorganise the settings screen a bit.

Quick plan to reorder some of the settings

I had the plan to use chips (if you don’t know what they are, there is a screenshot below) and allow users to reorder using them. I’ve never used them before and I had haven’t used drag and drop in Flutter before either. It took a couple of hours due to a silly little issue which had me stumped (thank you Stackoverflow – https://stackoverflow.com/questions/53585711/dragtarget-onwillaccept-and-onaccept-not-firing/53621273#comment94954839_53621273). At one point during the struggle, I was going to give up and use lists instead and maybe even “move up/down” buttons, rather than fancy drag and drop, but I wanted to have my chips! I persisted and got it to work.

Chips which allowed reordering of favourite stops by using drag and drop.

It worked okay on the simulator, but it felt a little bit fiddly. I got it to work really well and then decided to test it on a real phone. I’m not happy. It is pretty awful. It’s difficult to get the chips to land where they should and the chips are much bigger on the real phone, which meant that each one was on its own line any way. This would not really help a user very much and probably frustrate them.

I’m going to do it over again – I’ll probably just use a list view with up and down buttons. It is unfortunate, because I liked the look of the chips in general, but it’s just not practical.

Back to the beginning for me now…