Problem/Motivation
The diff engine allows you to configure how much context you want to display using the diff_context_lines_leading and diff_context_lines_trailing variables, but the variable system will not be available in Drupal 8.
Proposed resolution
Convert the following lines to use CMI:
core/lib/Drupal/Component/Diff/DiffEngine.php
1099 $this->leading_context_lines = variable_get('diff_context_lines_leading', 2);
1100 $this->trailing_context_lines = variable_get('diff_context_lines_trailing', 2);
There is no UI to set these variables.
Remaining tasks
User interface changes
API changes
Related Issues
This is a child of #1775842: [meta] Convert all variables to state and/or config systems
Comment | File | Size | Author |
---|---|---|---|
#6 | 2102499-6.patch | 894 bytes | swentel |
#3 | 2102499-3.patch | 734 bytes | swentel |
Comments
Comment #1
catchIf this is going to stay a component, it should use settings rather than state.
Comment #2
catchAlso related to #1929270: [meta] Drupal-agnostic components should not be calling Drupal functions.
Comment #3
swentel CreditAttribution: swentel commentedComment #4
ianthomas_ukThat's still calling a Drupal function from Drupal-agnostic code (see #2)
Comment #5
Berdirsettings() is just wrapper for Settings::getSingleton() (which is in Component\Utility), we can use that.
Comment #6
swentel CreditAttribution: swentel commentedOk, this then.
Comment #7
BerdirOk, let's do this. I don't want to look at this file anymore ;)
Comment #8
catchCommitted/pushed to 8.x, thanks!
Comment #9
swentel CreditAttribution: swentel commentedLooks like you forgot to push.
Comment #10
webchickCommitted and pushed to 8.x. Thanks!