Commit Graph

46 Commits

Author SHA1 Message Date
Matt Pass
2c28af0dd7 Check if !ctrlKeyDown on deciding on change
An estimated 20% of the time CTRL+key combos would register as a change.
Readded checking on !ctrlKeyDown to fix this.
2013-01-24 07:54:25 +00:00
Matt Pass
61f132327d Type boosting on function, removed fallback
Removed 'f ' as a type booster, now being more specific by requiring the
user type 'function'. This is consistent with if and for. It also won't
work as the autocomplete script will want to trigger instead and display
items starting with 'f'.
Removed showing the snippet display as a fallback.
2013-01-23 19:39:59 +00:00
Matt Pass
0d38b23a60 Fixed tab filename display & rename title
Simplified background on .tab class, also set it to relative positioning
and removed text having a RTL direction and being right aligned. Then
set the .closeTab class to also be absolutely positioned and 7px from
the right edge. Now the text is left aligned and close tab link right
aligned!
Renaming open tabs also now updates title
Fixed 2 x titles to have slashes at start now we aren't using RTL
direction
2013-01-22 20:26:08 +00:00
Matt Pass
07fd0ab6bf Fixes to rename processes
renameFile didn't have i var set, so I have set this to be what is
expected so we can now rename open files again.
shortURL was having it's slashes replaced with pipes in a few areas but
not all which meant it wasn't changing the onmouseover argument. Now
doing this on setting the var now which means a fix and less code.
Also forgot to alter the title attribute, now changing that on rename
too.
2013-01-22 20:01:54 +00:00
Matt Pass
74f678076a Don't update openFiles array on upload
Calling updateFileManagerList now includes a 6th argument and if a true
value is passed, then it's indicating an uploaded file and shouldn't set
the openFiles array value.
2013-01-22 18:49:48 +00:00
Matt Pass
449e8e2c4a Function to show the ICEcoder manual
Shows the manual in the mediaContainer popup, also passing through the
version number so in the future we can show relevant info.
2013-01-18 17:07:09 +00:00
Matt Pass
27da7ed0fe Close all tabs function added
Close button added to left of tabs as close all button. Simple styling
added to match tabs. closeAllTabs function added to close all tabs from
last back to first.
2013-01-18 12:13:09 +00:00
Matt Pass
685116c555 Can now pass mode argument to switchMode()
Allows you to set a mode to use via the API
2013-01-18 11:50:16 +00:00
Matt Pass
b49a2cc52d 2 new functions to select & submit uploaded files
Select function sets uploadedDir hidden form field and clicks the file
input button for user. Submit function is automatically triggered when
files value changes, which then shows the loading screen and submits the
form. preventDefault is also needed here.
2013-01-15 11:45:06 +00:00
Matt Pass
deb3ad5359 Logout link added
Logout link added to left of version no, next to logo in top right
Clicking this triggers the logout function, which directs the browser to
the same window location with ?logout QS
The settings.php file is run again (via inclusion) and finding the QS
var, sets the loggedIn var set to false (as a double measure to the
session also being destroyed) and header location boots user back to
login screen
2013-01-13 14:37:36 +00:00
Matt Pass
ca8e92e443 Establish cM and consider in if statement
Avoids errors on content = cM.getValue line
2013-01-13 13:09:46 +00:00
Matt Pass
482a5cfb11 Now loads snippet-display.php from lib folder 2012-12-30 17:12:30 +00:00
Matt Pass
9034e1ad45 for added as a abbreviation 2012-12-30 17:06:31 +00:00
Matt Pass
f181cef9e9 No need for space var, lCLen-4 not 3 2012-12-27 17:56:47 +00:00
Matt Pass
dd19c39cf8 Declaring function vars and adjusting var name
Establishing vars at beginning of function to stop them being globals
lineNo2 now lineCount
2012-12-27 14:33:07 +00:00
Matt Pass
5887a9c755 Tabs contain only filename
No longer show path as well
(This is now shown on hover)
2012-12-27 13:37:05 +00:00
Matt Pass
4afbe4c2fc Only add tags to array if not undefined 2012-12-27 11:37:58 +00:00
Matt Pass
6cf36cc99c No longer include a space after comment tag
Remove space after comment tags such as //, /* and #
This is to avoid JS Hint errors and also be less stylised
2012-12-27 11:23:06 +00:00
Matt Pass
fdf1ef1cb7 Now considering indents and better templates
Indents are now considered when completing the snippet
Replaced the mix of various template elements with uppercase
alternatives (VAR, INDENT & CURSOR)
2012-12-21 08:43:25 +00:00
Matt Pass
4797ff84d8 Quick effort at getting snippet notations working
You can now press CTRL+space to have your shorthand notation completed.
2 options for function and if setup so far.
What I've written is a pretty horrible hacky effort to get this working.
It does work but needs a LOT of refining.
2012-12-20 22:12:27 +00:00
Matt Pass
3937d733f0 QS var cleaning, removing test logs and /
strClean on GET var selectedFiles
Remove 2 x console.logs
Remove commented text
2 x areas need first slash removing and ending with a slash
Need to var thisWidth to avoid global
2012-12-20 17:15:26 +00:00
Matt Pass
80c73523e3 No need to globally replace end colon
There will be only one
2012-12-18 08:49:07 +00:00
Matt Pass
8c5747798d Tabs now have closelink fist as it's RTL and clear first slash and end
with one for same reason
Else if conditions to give better perf
newBlock has a z-index of 1000 to show above code
Show titles on tab hovers
New setTabWidths function to reset tab widths on demand
2012-12-17 09:06:46 +00:00
Matt Pass
2a2cd81149 Pass thru list of selected files on find/replace
If we choose selected files when performing a find/replace, build up a
colon seperated list and tack on as a querysting
2012-12-17 08:29:12 +00:00
Matt Pass
2bb961b7a8 Now only loads & runs if JSHint is available
Script only loads if file is available
Processes in function only run if JSHINT is available
2012-12-13 09:16:13 +00:00
Matt Pass
01b035d7af Clear or set JS Hints based on codeAssist
On toggle of codeAssist and being false, clear all JS Hint widgets in
all tabs
If turned on though, set in current tab
Run updateHints on switching tab (helps complete above step)
2012-12-13 08:56:53 +00:00
Matt Pass
2ebec54476 Line Wrapping and Banned Paths Options
New options available to set in the settings screen
Also passes through to useNewSettings function for in session changes
A couple of other minor changes to style and layout
2012-12-12 17:56:43 +00:00
Matt Pass
0f989f249f Moving function to the info & display section 2012-12-12 09:23:02 +00:00
Matt Pass
6980bdcf7f No need for 3rd arg here 2012-12-11 18:05:11 +00:00
Matt Pass
8e10824189 Sent argument and returned objected are different
It now takes a {line, ch} object as second argument, instead of an
integer, and will return a {from: {line, ch}, to: {line, ch}} object.
2012-12-11 11:53:06 +00:00
Matt Pass
3427b736ec New updateHints function for JS Hint
Calls on JS Hint and returns with any errors and shows as a widget under
relevant line
This example code taken from CodeMirror's Widgets example
2012-12-10 17:54:43 +00:00
Matt Pass
b206f8ab78 Remove caretLocType in nest & add/removeLineClass
Don't end the nestDisplay with the caretLocType, this is shown already
near the line/chr counter
For some reason, the array pos of the visible tabs is 4 not 5
Use new removeLineClass and addLineClass methods instead of setLineClass
2012-12-03 19:10:36 +00:00
Matt Pass
72ff461b45 Nesting tags now have BG chevrons
Slight adjust to make text in footer look in line
'cursor nest locaton' wording starts with lowercase c
BG gif added which contains start, middle and end chevron graphics
Now showing DIV containing BG for start, middle or end chunks between
next tag names
2012-12-01 14:35:03 +00:00
Matt Pass
96fe7d46ba Scroll selected range into view
On hovering mouse over nest tags, scroll the start of the selected range
into view
2012-11-28 17:26:45 +00:00
Matt Pass
4b17d76144 Extend 10 tabs to 100 tabs
10 tabs can sometimes be too few no one should ideally need more than
100 tabs open so this is a good new level.
Doesn't appear to impact on DOM or JS at all, especially as I don't need
to rework code to move to an unlimited tabs setup instead.
Having a limit also helps save crashing or bogging down the browser.
2012-11-25 14:18:36 +00:00
Matt Pass
99dedb61cb copyFile, pasteFile & hideFileMenu functions
copyFile simply sets a var same as the provided selFile var then hides
menu
pasteFile adds a paste file item to the server queue and shows message
hideFileMenu added as the opposite of showFileMenu function
2012-11-12 09:25:32 +00:00
Matt Pass
f24aaf1396 Added key exclusion back in
Was causing occasional issues with keypresses. Maybe 10% of the time.
Added this back in until I stop this function being triggered on
anything but changes.
2012-10-30 13:40:14 +00:00
Matt Pass
725461f04e Make searches case insensitive by default
This is to match finding in files and is typically the default.
Need to extend this logic to find in all documents and also filenames.
Also add case insensitive switch to find/replace control.
2012-10-26 18:36:33 +01:00
Matt Pass
b4c45e33e9 Better clearing of mouseDown, hide serverMessage
mouseDown = false being set now on scoll on iFrame (of File Manager) and
via CM instance for editor, so old method removed
Set serverMessages' display to inline-block when showing, none in 0.2s
when hiding
2012-10-25 11:46:32 +01:00
Matt Pass
139bfe775c Don't need key, simplify setting changedContent 2012-10-23 20:00:18 +01:00
Matt Pass
2bb0a361aa Clear mouseDown state if over scrollbar
Clicking on scrollbar to scroll content set the mouseDown state to true
This wasn't being reset on mouse up and moving mouse pointer towards the
edge of the file manager enabled resizing of width
Now on going beyond editor width (-scrollbar of 20px), sets mouseDown to
false
2012-10-23 15:57:50 +01:00
Matt Pass
5517bf80f9 Fixing close tab issue & changedContent setting
When redoing changedContent values, no longer consider if these keys are
being pressed:
Escape (27), Caps Lock (20), Shift, CTRL, Alt, Pause/Break (16-19),
Left, Up, Right, Down (37-40), Num Lock, Scroll Lock (144-145), Insert,
Delete (45,46) <<-- mistake, Page Up, Page Down, End, Home (33-36), Left
Win Key, Right Win Key (91-92), F1-F12 (112-123)
This is because CM's changed event will not be triggered with these keys
and I'm not calling onkeypress anymore
Also, rather than now just setting and ending up being stuck at 1 (ie,
changed), we're now detecting if we have at least 1 undo level, if so
set to 1, otherwise 0
(This means you can make changes and undo back to the start and it
doesn't count as a change)
Because this is being handled on changedContent array, no longer need to
consider undo level size when figuring out close button BG colour
openFileMDTs were not being shuffled along when closing tabs but are now
Fixed issue with string replacing closeTabButtonX() - brackets not
needed
2012-10-23 15:14:36 +01:00
Matt Pass
13255bc58b Clearing global vars
theme, tabsIndent, openLastFiles, tabWidth, previousFiles, showFileMenu
& foldStyle all now contained within ICEcoder object
showFileMenu is a function to ensure file manager menu continues to show
The few instances of i now have scope
Initing the var fileName
This is to reduce the number of global vars
The only global vars should now be ICEcoder, docRoot & iceRoot
2012-10-20 23:52:36 +01:00
Matt Pass
70a69f1c3b stickyTabWindow now stickyTab
Removed the flag variable stickyTab and stickyTabWindow now becomes this
Saves excess vars
2012-10-20 16:44:55 +01:00
Matt Pass
16e3e92c4a Fullscreen icon now changing on event handler
No longer detecting current image src and showing the opposite icon on
click
We're now changing the icon on screen change event handler
2012-10-20 16:14:56 +01:00
Matt Pass
9ed344d22d Renamed to ice-coder.css and .js 2012-10-09 08:21:28 +01:00