Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Show FormDiff modeless. #4807

Merged
merged 3 commits into from Apr 10, 2018
Merged

Conversation

jbialobr
Copy link
Member

@jbialobr jbialobr commented Apr 8, 2018

What did I do to test the code and ensure quality:

  • Manual tests.

Has been tested on (remove any that don't apply):

  • GIT 2.15
  • Windows 10

@jbialobr jbialobr added this to the 3.00 milestone Apr 8, 2018
@codecov
Copy link

codecov bot commented Apr 8, 2018

Codecov Report

Merging #4807 into master will increase coverage by 0.17%.
The diff coverage is 7.69%.

@@            Coverage Diff             @@
##           master    #4807      +/-   ##
==========================================
+ Coverage   30.49%   30.66%   +0.17%     
==========================================
  Files         519      520       +1     
  Lines       41880    42023     +143     
  Branches     5898     5908      +10     
==========================================
+ Hits        12770    12887     +117     
- Misses      28586    28610      +24     
- Partials      524      526       +2
Impacted Files Coverage Δ
GitUI/GitUIExtensions.cs 0% <ø> (ø) ⬆️
GitUI/CommandsDialogs/RevisionDiff.cs 4.73% <0%> (+0.02%) ⬆️
GitUI/UserControls/RevisionGrid.cs 8.81% <0%> (+0.16%) ⬆️
GitUI/GitUICommands.cs 0% <0%> (ø) ⬆️
GitUI/CommandsDialogs/FormFileHistory.cs 15.2% <100%> (+1.75%) ⬆️
GitUI/CommandsDialogs/FormDiff.cs 12.1% <33.33%> (+0.15%) ⬆️
UnitTests/CommonTestUtils/GitModuleTestHelper.cs 70% <0%> (-2.5%) ⬇️
...CommandsDialogs/AboutBoxDialog/FormContributors.cs 92.72% <0%> (-0.38%) ⬇️
GitUI/CommandsDialogs/RevisionFileTree.cs 8.3% <0%> (-0.1%) ⬇️
GitUI/CommandsDialogs/FormSettings.cs 10.63% <0%> (-0.08%) ⬇️
... and 41 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f21256a...c850d02. Read the comment docs.

{
diffForm.ShowDialog(this);
}
var diffForm = new FormDiff(UICommands, this, baseCommit, headCommit.Guid,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we could introduce a method, no!?!

@jbialobr jbialobr changed the title Show FormDiff modeless. [WIP] Show FormDiff modeless. Apr 9, 2018
@RussKie
Copy link
Member

RussKie commented Apr 9, 2018

Could you please provide a bit more info on the nature of the change and the benefits it brings?

@drewnoakes
Copy link
Member

Can't speak for @jbialobr but I am in favour of anything that converts modal forms to non-modal ones. Workflows with GE involve multiple windows and when you can't click between them it's really frustrating. I understand there are cases with technical reasons behind them, but they're just limitations of the design rather than some fundamental problem, so we should work towards removing modality where possible.

@jbialobr
Copy link
Member Author

jbialobr commented Apr 9, 2018

As @drewnoakes said, there are cases when you need some data from other forms (mostly main form) and when the FormDiff is modal you can't go to the main form to see the data. Scenario: you are in the middle of reviewing in FormDiff and want to read the commit message of the commit that introduced a change you are looking at.

I changed it to WIP because FormDiff depends on revisionGrid. I have to remove that dependency to make it work properly.

OpenWithDifftool does not need RevisionGrid. It needs IWin32Window and GitModule.
It fits better as a member of UICommands.
FormDiff receives only immutable dependencies and can be shown modeless (is invariant to repo change).
@jbialobr jbialobr changed the title [WIP] Show FormDiff modeless. Show FormDiff modeless. Apr 9, 2018
@RussKie
Copy link
Member

RussKie commented Apr 10, 2018 via email

@jbialobr jbialobr merged commit 82a9243 into gitextensions:master Apr 10, 2018
@jbialobr jbialobr deleted the jb/cmpMergeBase branch April 10, 2018 09:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants