Commit graph

422 commits

Author SHA1 Message Date
Ed Sanders 8070f48d27 Extension inspector directionality
Use a dir string instead of isLtr boolean like we do everywhere
else. Also use this.constructor.static, not this.static inside
methods.

Fixes Ie0525628.

Bug: 64072
Change-Id: I5321b71a446802d89ca86d55a0bff855b69825eb
2014-04-17 22:00:36 +00:00
jenkins-bot 564e77bc43 Merge "Allow MWExtensionInspector to be set to forced LTR status" 2014-04-17 03:21:17 +00:00
jenkins-bot 07a7708da1 Merge "Follow redirects in the category widgets" 2014-04-17 02:44:41 +00:00
Trevor Parscal 926700fbca Re-split the transclusion dialog
We used to have two dialogs; a complex one, and a subclass that dumbed it
down - this was rubbish.

Then we merged them together - this was a'ight.

Now we have two dialogs again; a simple one, and a subclass that fancies
it up a bit - this is wicked keen broham.

Change-Id: I4b2ba31bed5c4f80940623702d635cacd19e0a66
2014-04-17 01:39:18 +00:00
James D. Forrester 0e4676e6a9 Allow MWExtensionInspector to be set to forced LTR status
This is used in e.g. the formula editor and it's potentially useful.

Change-Id: Ie05256285e517c2d0d464822befbf81f2d9209e3
2014-04-16 18:34:26 -07:00
Roan Kattouw 4fc08d24c5 Make the Add template button not wrap to the next line
By default, MWTitleInputWidgets are now 30em wide, but this doesn't
work in the transclusion dialog where we want to put the "Add template"
button after an MWTitleInputWidget and have it not wrap to the next line.
So make the MWTitleInputWidget on the add template page 20em wide instead
(this is what they all were before the default was changed to 30em).

Change-Id: I2f33a87427657f4e27939c401436c4ce6441208c
2014-04-16 16:24:45 -07:00
Roan Kattouw 9d1b7432fd Also focus surface in media edit dialog
16ec8ffdcf did this for the reference dialog, but the media edit
dialog needs it too. Additionally, we need to focus it when the
user switches to a different page then comes back.

Bug: 63909
Change-Id: If1b9587f4d10dbe6374e987b35c781954bcc566d
2014-04-16 15:12:39 -07:00
jenkins-bot 4d6a59b16b Merge "Focus the surface in the reference dialog after it opens" 2014-04-16 19:00:51 +00:00
Roan Kattouw d335e59330 Fix another surfaceModel.getFragment() in MWCitationDialog
Change-Id: Ic12652bf3d53396f84d558595ce1e4a2d0a22796
2014-04-16 11:42:15 -07:00
Roan Kattouw 16ec8ffdcf Make inserting reference lists work again
surfaceModel.getFragment() is a null fragment, use this.getFragment()

Bug: 64012
Change-Id: I995929ff0dda60220e17e579994b51ffb406f149
2014-04-16 11:40:26 -07:00
jenkins-bot e708595f14 Merge "Make fieldsets render properly" 2014-04-16 18:27:16 +00:00
Moriel Schottlender fa72f5fdc2 Border checkbox disabling/enabling fix
Due to a lack of clarity in the wikitext documentation the border
checkbox wasn't set up right. This is the proper behavior: border is
allowed for all unframed images (frameless and basic) while the
framed images (frame and thumb) have it anyways. Wikitext
documentation was also clarified for prosperity.

Change-Id: I4dd4775da473d669781553796be99646240c13fe
2014-04-16 13:14:58 -04:00
Krenair 9c2e1d8048 Follow redirects in the category widgets
Display the redirects nicely in the UI, etc.

Bug: 52414
Change-Id: Ib62144cb90899d0c525d6f08f6b5f1159b7d2a86
2014-04-16 15:30:14 +00:00
Moriel Schottlender 8d99aa88c8 Fix border checkbox
Make sure border is enabled for unframed types and disabled for
framed images.

Change-Id: I716e9bc4140fbc09aac52930d1dd8213f31617a3
2014-04-16 00:03:35 -04:00
jenkins-bot 24071290a8 Merge "Fix name of advanced settings page in open command" 2014-04-16 02:57:30 +00:00
Krenair 96cdfe28ce Fix name of advanced settings page in open command
Bug: 63984
Change-Id: I924520be81a183a1de3f8f81c60d9ed26fb3a80e
2014-04-16 02:08:30 +01:00
Roan Kattouw b764ecc7f4 Focus the surface in the reference dialog after it opens
Otherwise the surface ends up in a weird half-focused state which
causes it to behave strangely.

Bug: 63909
Change-Id: I3ebc30fde0202116b383a5b497aca65b66732922
2014-04-15 22:25:41 +00:00
James D. Forrester 37030882d1 Fix fencepost error with MWMoreParametersSearchWidget overflow
The logic was checking that there were at least three items to show, then triggering
the MWMoreParametersResultWidget widget with the number of items left in the overflow
if the limit was two. Whoops. :-)

Change-Id: Icec16a2d26bef8bf8d74ed619341afd494ca0479
2014-04-15 12:30:40 -07:00
Trevor Parscal 9cd05d05a0 Make fieldsets render properly
Depends on I797ec22 in OOJS-UI

Change-Id: I3841bc50346e67dfe92814ebe337fd92365ae1d4
2014-04-15 11:47:15 -07:00
Trevor Parscal 9e6451d40c Fix inserting references list while selecting another kind of node
There are two ways dialogs determine if they are inserting or updating.

1. They evaluate whether the dialog is inserting or not and set a boolean
   flag, used later to steer the saving code

2. They evaluate whether the dialog is inserting or not and, if not,
   store the node to be updated in a property, used later to steer the
   saving code

In the reference list dialog, setup used strategy 1, and teardown used
strategy 2. We've now normalized to use strategy 2 in both methods, which
fixes this bug.

Bug: 61885
Change-Id: I1b077b2aef4121328bce2b373874dd7373e405a1
2014-04-14 19:44:28 +00:00
Roan Kattouw 2d671a38a2 Also set requiresRange for CitationDialogTool
The citation tools weren't being greyed out when the selection was null

Change-Id: I7d4d486a010f4c1301f3081661e7f343c24452df
2014-04-11 12:19:04 -07:00
Roan Kattouw b54b517dbc Followup b2296bdd2: the property is called requiresRange, not requiresFocus
Change-Id: I09937603e1957f1acbdbe4cc56e47e00f31c892b
2014-04-11 11:59:55 -07:00
jenkins-bot d8453acff5 Merge "Remove remaining uses of surfaceModel#getSelection in dialogs" 2014-04-11 18:43:14 +00:00
Ed Sanders 340a939c97 Remove remaining uses of surfaceModel#getSelection in dialogs
These were being used indirectly in the MW*Model's. Use surface
fragments instead.

Fixes I0fae3e5ff2bd.

Change-Id: I1d6aa5e00a9315cf7088f87f9e9d828833feec64
2014-04-11 11:14:43 -07:00
Ed Sanders b2296bdd2a Disable MW tools when surface loses focus
Bug: 62410
Change-Id: I00fa2de637b2c1f2a57c8c1f09e90f71285feab7
2014-04-10 12:01:47 -07:00
Ed Sanders 0e51180709 Update VE core submodule to master (55a5cdc): use new ve.ui.Dialogs and ve.ui.Inspectors
Move various bits of code from initialize to setup as required.

MWDialog is now useless so use ve.ui.Dialog directly.

New changes:
0b2d03f [BREAKING CHANGE] Pass fragments, not surfaces, to windows (reprise)
0101ac4 Update OOjs UI to v0.1.0-pre (ac6848398c)

Change-Id: I0fae3e5ff2bd0da5b74c244af226b07b1f5883bd
2014-04-09 20:28:30 -07:00
Roan Kattouw f2422d916c Update VE core submodule to master (c150259) for scalable changes
ve.dm.Scalable is now a computational model for image scaling and
size manipulation. This commit adjusts the nodes and the edit and
insertion dialog to handle the new scalable model, and by that
use a centralized computational engine for all scaling and size
changes.

New changes:
3ec19fb8 Refactor Scalable functionality

Change-Id: I017a017924f544cc8bc9b7d8245335759ae0e890
2014-04-09 17:29:49 -07:00
jenkins-bot 93d2175901 Merge "Limit the number of initially visible parameters in the parameter search widget" 2014-04-09 23:06:13 +00:00
Trevor Parscal 70655da2b9 Limit the number of initially visible parameters in the parameter search widget
* Truncate beyond 3 parameters
* Add a special option class that, when clicked, shows the remaining parameters
* Use a special option class for the no parameters item instead of hacking the normal one
* Simplify the design of the no parameters item: no icon, centered text

Change-Id: Ia8259e91b42a59c2b08019df36217d485208ad99
2014-04-09 12:56:02 -07:00
Ed Sanders 164cf27299 Use new model directionality in MW
Depends on I2065e17020dc89 in core.

Change-Id: I6e99db601af58a9c4200f885887de451f9f70daa
2014-04-09 18:21:25 +00:00
Trevor Parscal 84ed719cd0 Additional initializeSelection methodicde
Changes:

* Change uses of initializeSelection to selectItem
* Use "choose" event to respond to deliberate item selection by the user

Depends on changes in OOJS-UI (Ib3826ed)

Change-Id: Ia167a70ca5f40b1f15adad30620fdb13ef0d02d7
2014-04-07 12:15:40 -07:00
Trevor Parscal fc94173ff6 Fix more intalize typos
Change-Id: I24e0b3a93c15cc8a781eb9a35d9ba09510db40bd
2014-04-04 17:13:34 -07:00
Trevor Parscal 9556467595 Revert edit mode tool's onSelect method
Turns out surfaces don't have access to targets after all.

Bug: 63503
Change-Id: Ib14291ce4efe4b3dd5579cd270828936b6a175ae
2014-04-04 00:04:29 +00:00
Trevor Parscal 793fbb0e24 Correctly insert or update citations based on template option
When using a tool that opens a citation or citation transclusion dialog,
the dialog shouldn't use edit mode unless the template in the node and the
template the tool would insert match.

Bug: 63452
Change-Id: I34a5a2da576247f4046da45f742bccc3cec22c5a
2014-04-02 16:38:34 -07:00
Roan Kattouw 03c5822b6b Update VE core submodule to master (c5f4f78)
Also update tools for changes in VE core.

New changes:
e4de14b Make tools use commands
e029817 Make getToolsForNode place primary commands first

Change-Id: I66575ee6d49e6b2f5a5f789978da98bb55e6dc5e
2014-04-02 16:30:12 -07:00
Trevor Parscal 9e38cafc9f Remove constructive flag from return to save form button
It doesn't create anything, so it shouldn't be constructive.

Change-Id: I97d6fc3c5f992033e55ee6cde48245b1e96ddc16
2014-03-31 15:31:43 -07:00
James D. Forrester f1471a59f3 MWMediaSearchWidget: Bump media search result size to 20
At 15 the new, taller dialog means we never get to search for more…

Change-Id: I255d93b8230f962579e1a07840b7cc209577876b
2014-03-29 00:08:59 +00:00
James D. Forrester e56b425120 Update VE core submodule to master (e972bb7)
New changes:
e972bb7 Split-up theme-specific styles

Local changes:
* Split-up theme-specific styles

Change-Id: I4af6c03413d49cb05031d439caf340ddef996355
2014-03-28 12:56:19 -07:00
Trevor Parscal 7e80d5dfa8 Rename CSS file to relate to actual style names
Change-Id: Iece39a7cb34ea4a51e5aba10df60ea870bf912f8
2014-03-28 11:56:02 -07:00
jenkins-bot 50f9f2b983 Merge "Fix copyright year range for fourteen files not updated to 2011-2014" 2014-03-26 22:55:08 +00:00
jenkins-bot 927d24968d Merge "Make cite transclusion tools actually work" 2014-03-26 22:48:54 +00:00
Trevor Parscal ca95923d73 Make cite transclusion tools actually work
The transclusion tools shown in the toolbar in the reference dialog
passed a template to open with to the transclusion dialog, but it
didn't take that config parameter.

Moved this parameter up from CitationDialog to TransclusionDialog,
and moved its logic into the setup function.

Bug: 63037
Change-Id: I9249c845a5ae7cca2ec4d75d69e1236f7755d246
2014-03-26 22:42:30 +00:00
jenkins-bot 24efd6bd8d Merge "Blank the reference and media search queries when closing dialogs" 2014-03-26 21:49:36 +00:00
James D. Forrester 95dee3ceee Fix copyright year range for fourteen files not updated to 2011-2014
Change-Id: Ibef2bf965dbd970b235a57058bcb3922a8777aa2
2014-03-24 18:36:51 -07:00
James D. Forrester 3f21a91c2b Blank the reference and media search queries when closing dialogs
Bug: 61959
Change-Id: I45e161d322d4fb0a63d35c1a75a2a39ba9f73def
2014-03-24 17:41:29 -07:00
jenkins-bot 2b84bbbfca Merge "Use "Insert citation" label for apply button of CitationDialog" 2014-03-25 00:19:56 +00:00
Trevor Parscal c385c01096 Use "Insert citation" label for apply button of CitationDialog
* Create a method to produce the correct label
* Override that method in the citation dialog subclass

Change-Id: Ic74a23dcf30aae201f3d6c312b760cf058aadf11
2014-03-24 17:16:43 -07:00
Trevor Parscal 1363d15c53 Move cite to be after link, instead of after structure
Change-Id: I69170b68997b8df595cc12e10b3467444e3ae952
2014-03-24 17:13:59 -07:00
jenkins-bot cc45c6a0d1 Merge "Fix 'original dimensions' async call in MediaEdit dialog" 2014-03-24 22:54:01 +00:00
Roan Kattouw 81876bc81a Update reference's internal item after inserting reference
This fails before the reference has been inserted, because
it's not yet in keyedNodes at that point.

Bug: 63031
Change-Id: I34ea1a88c0f332c23e43597d1c42158bfb0f1e98
2014-03-24 15:05:26 -07:00