In PHPstorm , is any way to avoid save all open documents instead current active document? [duplicate] - save

My traditional workflow must be a little different to the PHPStorm default. I often work on multiple files at the same time and want to be able to save just one file when I've finished with it, without saving the others that I've modified.
I've managed to turn off the auto-save feature. Now, when I edit files I get stars on the ones I've edited and they stay like that until I hit 'save'. So far so good.
But when press CTRL-S to save, expecting it to save the one file I'm looking at so I can go back to the ones with asterisks to polish them off too, it also saves ALL the other files too.
I hope there's some way to change this behaviour or set up something to allow me to save just one file at a time!

Yes, you can .. but that still does not change a lot (e.g if you change your settings, or run/re-run something -- all files will be saved automatically anyway). Eventually (after few weeks or month of adaptation) you will get used to this behaviour and quite likely will love it (yes, this means changing working habits a bit, which is quite hard to do (requires time) for some people/in some cases).
Anyway ... to enable "save single file" functionality:
Settings | Keymap
On that screen, in search box type "save"
The action you are after is called "Other | Save Document"
Assign whatever shortcut you want.
P.S.
This action will NOT ask for confirmation (same behaviour as standard save does).
P.P.S.
This action is available since PhpStorm v7 ONLY.

Related

How to save multiple files at once through delphi save dialog

I'm not able to save multiple files at a time in delphi save dialog box. Multiple files means I want save files without mentioning anything(or only asterisk) at "filename" field in delphi TsaveDialog. Please let me know how to achieve that.
Of course not, because that is not what it is intended for. You CANNOT obtain multiple filenames from a single save dialog. It only provides one filename at a time. That is by design.
I suspect what you really want is to prompt the user for just a folder path instead. Use the SelectDirectory() function (or the Win32 SHBrowseForFolder() function directly) for that, then you can create whatever files you need in that folder.
The save dialog doesn't save files. It allows the user to select file names. The save dialog doesn't support multiple selection so if you want to have a file dialog that allows multiple selections you need an open dialog. But an open dialog typically is used to select names of existing files, whereas a save dialog can specify a name of a file that does not yet exist.
Wildcards when entered into file dialogs are used to filter the displayed list of files. The file dialog won't return file names containing wildcards.
You imagine using wildcards, but how would you be able to do that and create new files? Wildcards are used to pattern match against existing files.
Maybe what you need is a folder selection dialog. Or perhaps you should ask the user for the name of the "master" file and then you generate the names of the "auxiliary" files using the master file name as a stem. I'm guessing because you've not told us any specifics behind your question.
My advice is to reconsider carefully what you are attempting to achieve. Think of all possible corner cases. Explore what UI idioms are used by other programs. Make sure you understand fully the capability of the file dialog controls. And then design your UI to fit with all of these constraints.

Dropbox iOS SDK "Broken"?```

I am trying to use the latest official version of the DropBox iOS Core SDK, in particular the DBRestClient, to efficiently keep a document tree up to date on my local computer. However, several features of the SDK don't seem to be implemented as you'd expect, and I was wondering whether I am doing something wrong, failing to understand something, or on the other hand just looking for features that aren't there.
Dropbox has (at least?) two kinds of entities it stores: files and folders. If I make a change to a file in Dropbox, I can detect it by a change in the file's "rev" string.
However, for folders, the rev string doesn't change when the contents changes. For example, it doesn't change in response to any of the following:
Adding a file
Deleting a file
Editing a file
Question 1:
Is this the expected behavior ? If so, does that mean that when I want to know if any of my Dropbox files have changed I must walk through the entire folder tree every time ?
Deltas:
There is a command to get a "delta" of the current contents (of something, the command takes no path parameters) related a "cursor" string. The command looks like it is supposed to return a record of edited files/folders along with a new "cursor" string specifying the current state. However, when I get the delta, the contents are always empty. If I make a change in dropbox, and then send back the previous returned "cursor", I still get an empty delta.
Question 2:
Are deltas currently working in the SDK, and if so can anyone tell me what I am doing wrong ?
Question 1: Yes, that's the expected behavior. Typically you would use delta to watch for changes.
Question 2: Yes, I would assume that delta is working. You haven't shown any code, so it's impossible to guess what's going wrong.

Delphi: Set Browsers Homepage

I want my application to be able to set IE, Firefox, Chrome & Operas homepages when a button is pressed. I understand IEs homepage is set in the registry, which I understand how to change, but can anyone give me any help with the others? Thanks
Chrome stores the homepage in a file called 'Preferences'. On Windows XP, this is located at;
C:\Documents and Settings\USERNAME\Local Settings\Application
Data\Google\Chrome\User Data\Default
On Vista+, it's located at;
C:\Users\USERNAME\AppData\Local\Google\Chrome\User Data\Default
This file is JSON format, and so it can be opened and viewed as plain text. In order to change the homepage, you'd need to load the JSON from this file, and change the homepage field value. You may also need to change the homepage_changed field value in order for it to stick. Using something like SuperObject to change the field would be an easy solution (if I get time, I'll write up some example code later).
Firefox uses a pref.js file to store it's settings, and realistically, a way of changing this would be to load this file, find the something that's along the lines of;
user_pref("browser.startup.homepage", "[URL]");
...and edit it as appropriate before saving the file. This should be a simple task using some simple find-and-replace code. I'd strongly advise that you use a pos() function though, as it could be that the end-user has already got their own custom homepage set and so searching for a preset string (e.g. [URL]) may not work, and certainly wouldn't be reliable.
A quick search hasn't given me enough information about Opera to provide a solution, but I'll keep looking and respond if I do find such a way.
Note that none of these methods have been tested and are merely provided based upon some very quick research.

How to migrate my files from one folder location to another with full user visibility

For years I've put my application data files in c:\MyCompany\MyDataFileFolder\App where 'App' is my application name. I made this choice in the early days of Wild-West-Windows when Microsoft seemed to keep changing its own mind (My Documents, Documents, Program Data etc). As I've learnt more about how to do things correctly, and as Windows has now 'settled down' and is more picky about permissions I'd like to move my files. Users have got used to where they are though, and what I'd really like to do is to implement something like Windows does with 'special folders' where there are several synonymous names, thus in my legacy folder I'd like to put something in (or change a folder to) an alias for the real location which will now be something descended from Program Data. This way, the files are in a good place with the correct permissions and if we run a utility expecting or modifying files in the 'old' place this gets changed transparently to the 'new' place (thus a simple shortcut wont work).
Is this possible? Is there are recognised technique for this? I'm using Delphi XE2.
What you are looking for is either a Symbolic Link or a Reparse Point.

How to set permission for Folder in Blackberry ?

I want to know how to set permission for folder that is created by my app so no one can delete or see that folder.
I think this is not 100% possible, however you may do smth in this direction. Check for FileConnection.setHidden(boolean), FileConnection.setWritable(boolean) and FileConnection.setReadable(boolean).
First of all, the API docs are vague as to whether those methods will have any effect at all on a specific device (meaning a file system).
Secondly, even if you use FileConnection.setHidden(boolean), then it is still possible for another app to "see" your file/dir by using FileConnection.list(String filter, boolean includeHidden). Once one has a path of you hidden dir, he/she can change the hidden attr (and other attrs), so it becomes visible/readable/killable.

Resources