Commit Graph

77 Commits

Author SHA1 Message Date
Edward Lee
74d4851978 Followup bug 580870 to rename gTabDeck/gTabFrame to gTabView*. 2010-07-22 22:41:58 -07:00
Michael Yoshitaka Erlewine
d393fc5668 Rewrote various scaling/easing functions in terms of the Range's, with the new proportion and scale methods.
- removed Math.tanh, instead moving it into the Range proportion method for its "smooth" option
+ rewrote TabItem close button opacity and title font size using the new Range utilities. Should make code a tad easier to follow.
2010-07-23 00:35:07 -04:00
Michael Yoshitaka Erlewine
bbeb43d86a Bug 581143: Cleanup geometry utilities in utils.js
1. Move isRect, isPoint, isRange to Utils, to facilitate JSMing and to clean up
namespace
2. Remove unused/underutilized methods of Rect/Point/Range
3. Use QuickDraw-style comparison of pixel overlap (using < instead of <=)
throughout.
4. Range.overlaps is now Range.contains, to be more consistent with Rect.

--HG--
extra : rebase_source : cc3507bb3bbe92f922d3147cc9130c1f713391b2
2010-07-22 15:46:51 -04:00
Michael Yoshitaka Erlewine
8dd2ae9572 Bug 580878: removing some underutilized Utils functions: getMilliseconds, and testLogging
--HG--
extra : rebase_source : 28ff49903f395240a3aca3b3761c7638ee6d4b7d
2010-07-22 15:42:29 -04:00
Edward Lee
ff7ecda676 Bug 581078 - Get rid of Utils.activeTab to avoid iterating over all Tabs
Directly access gBrowser.selectedTab and compare other raw tabs against it until BrowserTab goes away. Get the reference to the BrowserTab instead of iterating over Tabs through .tabcandyBrowserTab.
2010-07-22 12:36:17 -07:00
Edward Lee
b3a2d799b2 Bug 580870 - Alias gBrowser to the tabcandy context to remove getCurrentWindow
Add aliases for gWindow, gBrowser, gTabDeck, gTabFrame for the tabcandy chrome context. Update uses and simplify some code like removing Navbar.
2010-07-22 12:34:13 -07:00
Michael Yoshitaka Erlewine
5715d04263 rm stacktrace.js!
--HG--
extra : rebase_source : ee145386d3b3836f0c02005c1f4f7ef517377b7e
2010-07-19 14:21:09 -04:00
Raymond Lee
49b66e7e06 Fixed Bug 579814 - Fix behavior of tab-manipulation keyboard shortcuts 2010-07-19 17:37:22 +08:00
Michael Yoshitaka Erlewine
226027a6be rm trailing whitespace 2010-07-18 11:58:10 -04:00
Ian Gilman
1347f6d788 + Finished documenting all of the app code, plus utils.js. Remaining: iq.js, mirror.js, tabs.js 2010-07-16 17:27:01 -07:00
Raymond Lee
689f8adb2e Bug 577445: Show tab candy title in the tab candy interface and change 'let' to 'var' 2010-07-15 16:41:08 +08:00
Raymond Lee
764afcb66c Bug 576110: Show saved thumbnails at browser startup if tab candy was last open 2010-07-15 10:40:46 +08:00
Ian Gilman
a04cd8087e + Cleaned up a scope issue with Subscribable and added some guards 2010-07-14 17:24:03 -07:00
Ian Gilman
5a5575f98e + Subscribable (in utils.js) no longer has a separate onClose path
+ My recent addition of a "content" div broke dragging to make a new group; fixed
2010-07-14 16:59:37 -07:00
Michael Yoshitaka Erlewine
297f6910f6 cleanup: rm unused functions, constants from Utils + Mirror 2010-07-13 22:48:55 -04:00
Michael Yoshitaka Erlewine
39a1f66dc2 cleanup: rm iQ.grep; using .filter instead. 2010-07-13 20:23:04 -04:00
Michael Yoshitaka Erlewine
ce70751467 cleanup: rm various instances of iQ.each where it's an array, so we can use .forEach
--HG--
extra : rebase_source : f41f088641f71aba6796092766b0645fca925ad1
2010-07-13 19:38:51 -04:00
Raymond Lee
1edcad44f0 Bug 576110: Open tab candy at startup if it was last open 2010-07-13 12:04:04 +08:00
Michael Yoshitaka Erlewine
f11f97f9db bug 577968: control words like if, switch, etc. should have a space after them 2010-07-11 20:54:42 -04:00
Michael Yoshitaka Erlewine
7ecfb07c00 bug 577968: removing elses preceded by returns; replacing tabs 2010-07-11 19:48:05 -04:00
Ian Gilman
990ad5280a + started work on the first run experience: everything goes into a single new group, and there is an info item as well
+ Added "reset" to the dev menu so we can test first run (since the reset button is currently AWOL)
+ Added Utils.assertThrow(), an assert that throws an exception
2010-07-07 17:04:01 -07:00
Ian Gilman
8a017fdd19 + refactored Raymond's fix to Bug 576424 2010-07-02 16:33:33 -07:00
Ian Gilman
97ead3a57c + Removed placebo hack from Storage.wipe()
+ Removed TabItems.reconstitute(), which we haven't actually needed for a while, but now it's also causing trouble
+ Removed Utils.activeWindow, which doesn't seem to work, and replaced its use in Utils.activeTab (the only remaining place it was being used) with Utils.getCurrentWindow(), which does seem to work
+ Utils.assert() now dumps a trace
+ Fixed paths to the edit pencil and new tab button images; they should now show up properly
2010-07-01 17:05:46 -07:00
Raymond Lee
2f6fe85723 Bug 572889 - Move TabCandy out of a tab and into a per-window xul:deck [r=iangilman]
Update code for tabCandy in xul:deck to not assume it's living in a tab and update various events and callbacks.

--HG--
extra : rebase_source : 7007f13f4e9e3ebd0eb38f91d41bccfa68b3099d
2010-06-23 17:25:34 +08:00
Ian Gilman
bab211ee39 + If a dragged item overlaps more than one droppable, the largest intersection wins
+ Added intersection and area to Rect
+ Cleaned out a little debug code
2010-06-23 17:10:16 -07:00
Michael Yoshitaka Erlewine
d0fc5f695d just some comments to pushAway and related functions; rm legacy squishModes; pushAway now uses Trenches.gutter for margins, and respects safe window bounds 2010-06-22 19:50:37 -04:00
Ian Gilman
33f1e545e4 + In the quest to abolish reloadBounds(), I've rewritten draggable, droppable and resizable to operate on an item's bounds rather than directly on the div. I've also removed those routines from iQ, and integrated them into Item. Additional related cleanup and documentation.
+ Removed a little bit of aza debug code
+ Added size and position routines to Rect
2010-06-22 16:42:06 -07:00
Michael Yoshitaka Erlewine
742604caa6 + Range.overlaps; bugfix: border trenches unfortunately had an inappropriately large activeRange... fixed. This fixes the long-distance border-snapping which unfortunately shipped with 0.4 2010-06-21 22:32:07 -04:00
Michael Yoshitaka Erlewine
c13723d526 Rect now computes its own xRange and yRange 2010-06-19 18:47:26 -04:00
Michael Yoshitaka Erlewine
d99dee234f Range update 2010-06-19 17:37:36 -04:00
Michael Yoshitaka Erlewine
124719088a class Range 2010-06-19 16:58:51 -04:00
Ian Gilman
19713fb918 + Fixed: Bug 570089 - Dragging northwest in tabcandy area creates zero-area tab group 2010-06-18 14:42:06 -07:00
Ian Gilman
9d8648e238 + updated/added license blocks to all JavaScript files 2010-06-16 17:19:11 -07:00
Ian Gilman
2ba604b397 + removed unused code and reorged remainder 2010-06-16 15:46:05 -07:00
Ian Gilman
feff0a9435 + Cleaned up TabItem bounds getting and setting (the translation between our coordinates and the div style needs to be done carefully, in particular due to the padding in the tab style), and added a unit test for it 2010-06-15 15:55:47 -07:00
Ian Gilman
5216fa1524 + Started iQ, replacement for jQuery
+ Converted Utils.js to use iQ instead of jQuery
+ Removed the use of Firebug lite
+ Removed reference to jQuery.lint
2010-05-25 17:04:59 -07:00
Ian Gilman
c8eb4cf5e9 + New "new tabs" group behavior and position
+ New "new tab" button position for the  "new tabs" group
+ Misc bug fixes
2010-05-24 17:14:10 -07:00
Ian Gilman
ac6aa9b303 + Applied Ehsan's sessionstore patch
+ Various related fixes
+ Added Utils.log2, which logs directly to the window
2010-05-21 15:44:15 -07:00
Ian Gilman
5cc48c0893 + this marks the checkin where Ian has switched to Minefield and is no longer paying attention to 3.6
+ the TabCandy button/hot key now works to make a separate TabCandy for each window
+ Fixed a number of startup issues relating to multiple tab candies running at the same time
2010-05-20 16:56:19 -07:00
Ian Gilman
6bbee5b968 + Feature: When returning from a tab that is in a stack, arrange it at the top of the stack (but don't change its order in the children list)
+ TabItems now keeps track of all TabItem objects manually; we were using $('.tab:visible'), but this was causing bizarre behavior in certain cases
2010-05-18 17:08:45 -07:00
Ian Gilman
484ad3e488 + applied Dietrich's second patch; Listing candies (on the home page) now works in both 3.6 and minefield 2010-05-13 15:38:10 -07:00
Ian Gilman
cf86edc503 + Fixed: Quit Firefox with TabCandy open then open Firefox again. Your tabs and and navbar get hidden.
+ Fixed: If you quit tab candy (but not the browser), all of the tabs need to be reshown.
+ Starting firefox with tab candy selected now hides the tab bar
+ Utils.activeTab now returns a Tabs tab, rather than a raw tab
2010-05-13 15:14:08 -07:00
Ian Gilman
0e4e51be66 + patch from Dietrich to get Tab Candy running in Minefield (disables listing of candies) 2010-05-13 10:37:50 -07:00
Ian Gilman
207855a456 + Trying -moz-crisp-edges… doesn't seem to improve speed much on 3.6, and looks worse
+ Created Utils.copy to make duplicating objects cleaner
+ Fixed a number of issues with pulling tabs out of a tray. Temporarily disabled the delay on drag as well.
+ Improved the threshold for switching from grid to stack; only happens when the grid fills up.
+ No longer announcing "bad storage data" when there is in fact no storage data (fresh start)
+ A couple more asserts
2010-05-11 17:22:06 -07:00
Ian Gilman
ffba354eb3 + Fixed an extremely subtle bug that would cause groups that you hadn't manually resized to start falling apart after a refresh.
+ Added sanity checks on data going to and from storage (still some work to be done there); if the check doesn't pass, the data isn't loaded/saved
+ Added a manual save option to the dev menu
+ Added Utils.isNumber, as well as standalone isRect and isPoint routines
+ Miscellaneous double checks and assertions
2010-05-11 12:03:31 -07:00
Ian Gilman
5b300842e9 + The "new tabs" group can now not be renamed or closed, but it can be moved and resized. Updated how item locking works to accommodate this.
+ Groups now have some extra space at the bottom to accommodate for the "new tab" button
+ Items now unsquish after another item is closed, and on resize. This should cut down on random-seeming unsquishes later.
2010-05-07 15:49:54 -07:00
Aza Raskin
6aeb7dc566 + You can now click-n-drag in empty space to create a group. If the group is too small, it will animate away (the cancel action) and if they group contains orphaned tabs, lo', it pulls those tabs into itself.
+ Changed the behavior of removing the penultimate tab from a group. The group no longer goes away until the very last tab is removed.
+ Added some new rect utilities for finding if a point/rect is inside another rect
2010-05-06 16:28:10 -07:00
Ian Gilman
6ba8c7860f + Tabs dropped on stacks now appear on top
+ Misc fixes
+ We now show chrome tabs (but not the tab candy tab)
+ When the browser first starts up, it takes it a while for the tabs to all get their correct URLs; we now properly deal with this when reconnecting them to their groups
+ Added a "dev" menu in the upper left for various debugging features. Nothing much there so far
2010-05-03 15:32:11 -07:00
Aza Raskin
1bde7082e5 + We use to show tabcandy whenever we closed any tab. We now only focus tabcandy when the last tab in a group is closed.
+ TODO: Ideally, we should have an animation of the last tab be zoomed out into the tabcandy interface, and then that tab fading away along with the group (if the group is unnamed).
2010-04-30 23:50:43 -07:00
Ian Gilman
6ac56dfa95 + Fixed a bug making it so you couldn't close tabs that were just .mov
+ Commented out the _render routine in toolbar-button.js,  as it was throwing exceptions and didn't seem to work anyway
+ Added some asserts to Item and cleaned up its documentation
+ Made Utils.assert more robust
+ Made tabs prettier when stacked
+ Commented out js lint, which doesn't seem to work in this context
+ Fixed it so you can't resize locked groups
+ Made it so the "new tabs" group is no longer locked (for the time being at least)
+ Tabs no longer change order when you drag their groups around
+ The tray now goes away more beautifully
+ You now have to drag at least 100 pixels and at least 500 milliseconds before a tab is pulled out its tray
+ No longer reserving space at the bottom of the screen for the "new tabs" group
+ Tab titles now go away when stacked and come back when not (there was a problem with them coming back)
+ No longer explicitly positioning the "new tabs" group
2010-04-30 17:24:03 -07:00