
Last night I wanted to enhance the directory tab by making it so that users can select any directory they want. This is important to me as I wanted some way to get directly to pictures on a camera. By allowing the user to navigate the camera's directory, I could provide access, although in an admittedly cheesy and file centric manner. In the picture above, I am looking at pictures from the memory card from my wife's camera. It would be sweet to have proper camera integration some day.
It took me a couple of hours last night to move the tab into it's own class, as well as to actually implement the functionality for selecting and loading the directory. But now it's easy for me to work on the directory loading function. Note that directory selection is achieved via a new Quidget that I added. quidgets.prompts.choose_directory() yields a path to a directory. There is another refactoring to be done, which is to extract a base class for all of the tabs. However, I am refraining from doing any refactoring, unless it is required to add features.


So tonight I dinked around a bit with icons. I put the folder icon inside the button, and I used theme icons and some border_width to achieve some nicer buttons. There's still room for another button or two.

No comments:
Post a Comment