1
mirror of https://invent.kde.org/network/falkon.git synced 2024-11-11 17:42:10 +01:00
Commit Graph

51 Commits

Author SHA1 Message Date
David Rosca
825ee7ea96
Revert "TabContextMenu: Require only WebTab in constructor"
This broke context menu on empty tab bar space.

This reverts commit e791e77045b572af02d27f7a15ae082a4a13814c.
2018-02-05 16:44:39 +01:00
David Rosca
408b2ffad6
TabWidget: Add public webTab method
Also cleanup tabbedwebview.h includes.
2018-02-05 16:44:23 +01:00
David Rosca
9f4ac24cf8
TabBar: Initialize pinned tab width from real tab
Calculates the padding between tab border and icon from tabRect
instead of using style pixel metric which was oftentimes incorrect.

Pinned tabs should now have correct size and icon be perfectly centered
with all possible widget and qss styles.
2018-02-04 16:58:35 +01:00
David Rosca
0c7245fa9f
TabContextMenu: Require only WebTab in constructor 2018-02-04 16:58:08 +01:00
David Rosca
43e472e50e
TabBar: Disallow detaching tab when there is only one tab in the only window
Otherwise it would close the last window which would quit the app.
2018-01-31 21:05:48 +01:00
David Rosca
516bd92089 TabBar: Allow to change width of tabs using style sheets
It can be set in themes or in userChrome.css as in example.

/* userChrome.css */
TabBarTabMetrics
{
    qproperty-normalMaxWidth: 250;
    qproperty-normalMinWidth: 150;
    qproperty-activeMinWidth: 150;
    qproperty-overflowedWidth: 150;
    qproperty-pinnedWidth: 35;
}
2018-01-11 19:49:12 +01:00
David Rosca
21bd073482 TabBar: Increase drag start distance to not disturb tab moving
Also remove no longer needed timer to show add tab button.
2018-01-11 19:48:55 +01:00
David Rosca
49ebfa3f5d TabBar: Don't hide add tab button when moving tabs 2018-01-11 19:46:06 +01:00
David Rosca
84c4f0ff4d TabBar: Don't show context menu when dragging tab
Otherwise it breaks tabbar state.
2018-01-11 19:45:41 +01:00
David Rosca
78383c007e TabBar: Always send mouse events to ComboTabBar
It needs every event to correctly update dragInProgress property.
2018-01-11 19:45:36 +01:00
David Rosca
6a48f4d862 TabBar: Disable greying out not restored tabs
It doesn't really work with some themes and there doesn't seem
to be easy way to make the text always clearly visible.
2018-01-11 19:45:27 +01:00
David Rosca
5013053811 TabBar: Reject drags from other app instances 2018-01-02 22:57:26 +01:00
David Rosca
7b6b69c35f TabBar: Fix dropping text/url to tabs 2018-01-02 15:03:27 +01:00
David Rosca
90153e280e Fix build 2018-01-01 17:10:44 +01:00
David Rosca
8817493c68 Tabs: Allow to detach tab from window with only one tab
Window will be closed after detaching this tab.
2018-01-01 17:01:41 +01:00
David Rosca
38bfd49d4f TabBar: Change mimetype to falkon 2018-01-01 17:00:42 +01:00
David Rosca
fb652ff6cd Tabs: Make the code work better with zero tabs 2018-01-01 16:59:52 +01:00
David Rosca
21ca9adf6b TabBar: Add support for drag&drop tabs to other windows
Also it is possible to detach tab by dragging it outside of tabbar.

BUG: 386672
2018-01-01 16:58:47 +01:00
David Rosca
c679fdf397 TabBar: Add support for droping text/url inside tabbar to insert new tab 2018-01-01 16:57:03 +01:00
David Rosca
8100020b41 TabBar: Support dropping text on tabs
It will be searched for using default search engine
2018-01-01 16:56:47 +01:00
David Rosca
ca04e9d967 TabBar: Support adding new tabs with text drop data
Urls are loaded directly and text is searched for using default search
engine.
2018-01-01 16:56:32 +01:00
Razi Alavizadeh
f041d87534 Move tab context-menu methods to TabContextMenu. 2017-10-03 17:02:24 +03:30
David Rosca
d00e769749 Initial rename to Falkon 2017-08-25 17:32:32 +02:00
srazi
2654081912 Fix 2178 (#2292)
* CheckBoxDialog: Rewritten to inherit from QMessageBox

-  QMessageBox supports showing checkbox for Qt >= 5.2

* Add option to disable warning message when closing tabs from tabbar context menu.

- Closes #2178
2017-04-05 10:27:03 +02:00
David Rosca
bcb633fcd0 TabBar: Use correct duration for showing add tab button after releasing dragged tab 2017-01-28 10:31:45 +01:00
David Rosca
2d90afc503 TabBar: Don't return -1 when not visible in pixelMetric
Fixes tabs sometimes being invisible when leaving fullscreen

Correct fix for #1967
2017-01-27 15:34:29 +01:00
David Rosca
9082c32bae TabBar: Change close action text to "Close Tab" in context menu 2017-01-21 12:22:07 +01:00
David Rosca
9f20772238 TabBar: Fix scrolling to current tab after session restore 2016-12-26 14:35:25 +01:00
David Rosca
2eb0308f6f TabBar: Reorganize the context menu a little
Remove the "Bookmark this tab" action, move "Open closed tab" at
the bottom and show "New tab" only when clicking at empty space.
2016-10-25 19:24:47 +02:00
David Rosca
cf3fa88942 Require Qt 5.7 2016-10-24 20:11:50 +02:00
std46
e906f6ae20 Issue #2049 close tabs to right & close tabs to left (#2062)
* add close to right menu 
Closes #2049
2016-08-28 16:24:09 +02:00
David Rosca
5085111657 Merge branch 'v2.0' 2016-08-15 14:51:19 +02:00
David Rosca
4c7735139e ComboTabBar:: Call ensureVisible only after resize event is processed
Also change delay to call ensureVisible after current tab is changed
to 100ms
2016-08-15 14:47:30 +02:00
David Rosca
1a183e590b Merge branch 'v2.0' 2016-08-15 14:25:26 +02:00
David Rosca
42eadaeb2f Fix scrolling to current tab when added from fullscreen mode 2016-08-15 14:25:01 +02:00
Vlad
134737afda Implement audio mute for webtabs (#2019) 2016-08-05 10:50:50 +02:00
David Rosca
4cb62b73fb TabBar: Don't calculate tabSizeHint only when window is invisible
Fixes issue with tabbar sometimes having 1px height when leaving fullscreen.

Closes #1967
2016-07-10 16:34:05 +02:00
David Rosca
ac792de566 TabBar: Improve logic to calculate pinned tab width 2016-01-25 13:33:05 +01:00
David Rosca
35fd959315 HighDpi: Save site icons to database with 32x32px size 2015-10-24 12:50:42 +02:00
David Rosca
26644f8cb9 Fix build 2015-10-22 21:02:39 +02:00
srazi
33553a049a TabManager: Add an option to use it as main tabbar replacement.
- Note: in `TabBar::setVisible()` we didn't need to
  check `(visible && m_window->isFullScreen())` because tabbar's
  visibility in fullscreen mode is managed by m_navigationContainer.
2015-10-22 20:50:35 +02:00
David Rosca
1a068e8c7d Use QWebEnginePage::RequestClose action to close tabs
It is no longer to use hacky onbeforeunload javascript handling when
closing tabs.
2015-10-12 12:07:01 +02:00
David Rosca
53e4512d31 ComboTabBar: Fix showing tooltip when animating scrolling 2015-10-11 10:51:16 +02:00
David Rosca
b39809bfae Remove option to show tab previews 2015-10-09 16:03:38 +02:00
David Rosca
a0b84a5cd3 TabBar: Don't use ProxyStyle directly 2015-06-11 21:10:47 +02:00
David Rosca
72ab5de448 [Code] Small code cleanups
Mostly to silence a warnings from cppcheck

[ci-skip]
2014-06-05 20:33:16 +02:00
David Rosca
e6f4853af7 [TabBar] Show add tab button at correct position when there are no normal tabs
Fix 2 for #1322
Closes #1322
2014-05-02 20:15:05 +02:00
David Rosca
d1754094b8 [TabBar] Use contextMenuEvent instead of customContextMenu signals 2014-05-02 13:39:02 +02:00
David Rosca
6797433e39 [ComboTabBar] Fixed tabAt() on scroll buttons 2014-04-19 18:47:44 +02:00
nowrep
98907c2055 [WebTab] Reworked tab attaching/detaching.
This also fixes crash on detach
2014-04-01 18:47:19 +02:00