Skip to content

Commit

Permalink
Fix compressed tabs bouncing
Browse files Browse the repository at this point in the history
  • Loading branch information
jotaemepereira committed Feb 21, 2024
1 parent 77d568e commit befff3f
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 12 deletions.
21 changes: 10 additions & 11 deletions DuckDuckGo/TabBar/View/Base.lproj/TabBar.storyboard
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.Cocoa.Storyboard.XIB" version="3.0" toolsVersion="22154" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES" initialViewController="uSf-9n-QMw">
<document type="com.apple.InterfaceBuilder3.Cocoa.Storyboard.XIB" version="3.0" toolsVersion="22505" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES" initialViewController="uSf-9n-QMw">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="22154"/>
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="22505"/>
<capability name="Named colors" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
Expand Down Expand Up @@ -62,7 +62,7 @@
<rect key="frame" x="0.0" y="0.0" width="845" height="38"/>
</customView>
<stackView distribution="fillEqually" orientation="horizontal" alignment="top" spacing="0.0" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" detachesHiddenViews="YES" translatesAutoresizingMaskIntoConstraints="NO" id="kOb-4q-pAe">
<rect key="frame" x="76" y="17" width="0.0" height="0.0"/>
<rect key="frame" x="76" y="18" width="0.0" height="0.0"/>
<subviews>
<button hidden="YES" translatesAutoresizingMaskIntoConstraints="NO" id="7XG-Qm-Ksx" userLabel="Left Scroll Button" customClass="MouseOverButton" customModule="DuckDuckGo_Privacy_Browser" customModuleProvider="target">
<rect key="frame" x="0.0" y="-28" width="28" height="28"/>
Expand Down Expand Up @@ -99,13 +99,13 @@
</customSpacing>
</stackView>
<scrollView wantsLayer="YES" borderType="none" horizontalLineScroll="10" horizontalPageScroll="10" verticalLineScroll="10" verticalPageScroll="10" hasVerticalScroller="NO" verticalScrollElasticity="none" translatesAutoresizingMaskIntoConstraints="NO" id="O0X-yp-zLn" customClass="TabBarScrollView" customModule="DuckDuckGo_Privacy_Browser" customModuleProvider="target">
<rect key="frame" x="76" y="0.0" width="683" height="34"/>
<rect key="frame" x="76" y="0.0" width="683" height="36"/>
<clipView key="contentView" drawsBackground="NO" copiesOnScroll="NO" translatesAutoresizingMaskIntoConstraints="NO" id="zdf-RD-hTG">
<rect key="frame" x="0.0" y="0.0" width="683" height="34"/>
<rect key="frame" x="0.0" y="0.0" width="683" height="36"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<collectionView selectable="YES" allowsEmptySelection="NO" translatesAutoresizingMaskIntoConstraints="NO" id="OEu-5P-cRF" customClass="TabBarCollectionView" customModule="DuckDuckGo_Privacy_Browser" customModuleProvider="target">
<rect key="frame" x="0.0" y="0.0" width="683" height="34"/>
<rect key="frame" x="0.0" y="0.0" width="683" height="36"/>
<autoresizingMask key="autoresizingMask" heightSizable="YES"/>
<collectionViewFlowLayout key="collectionViewLayout" scrollDirection="horizontal" id="oAv-jh-KDw">
<size key="itemSize" width="120" height="32"/>
Expand All @@ -122,11 +122,11 @@
<edgeInsets key="contentInsets" left="0.0" right="0.0" top="0.0" bottom="0.0"/>
</clipView>
<constraints>
<constraint firstAttribute="height" constant="34" id="7Y5-9k-rSZ"/>
<constraint firstAttribute="height" constant="36" id="7Y5-9k-rSZ"/>
</constraints>
<edgeInsets key="contentInsets" left="0.0" right="0.0" top="0.0" bottom="0.0"/>
<scroller key="horizontalScroller" wantsLayer="YES" verticalHuggingPriority="750" horizontal="YES" id="f6A-N1-Ed1">
<rect key="frame" x="0.0" y="18" width="683" height="16"/>
<rect key="frame" x="0.0" y="20" width="683" height="16"/>
<autoresizingMask key="autoresizingMask"/>
</scroller>
<scroller key="verticalScroller" hidden="YES" wantsLayer="YES" verticalHuggingPriority="750" horizontal="NO" id="tXZ-5R-7cy">
Expand All @@ -135,7 +135,7 @@
</scroller>
</scrollView>
<stackView distribution="fillEqually" orientation="horizontal" alignment="top" spacing="2" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" detachesHiddenViews="YES" translatesAutoresizingMaskIntoConstraints="NO" id="dN1-y1-5Xe">
<rect key="frame" x="763" y="3" width="70" height="28"/>
<rect key="frame" x="763" y="4" width="70" height="28"/>
<subviews>
<button hidden="YES" translatesAutoresizingMaskIntoConstraints="NO" id="2da-G7-xcP" userLabel="Right Scroll Button" customClass="MouseOverButton" customModule="DuckDuckGo_Privacy_Browser" customModuleProvider="target">
<rect key="frame" x="0.0" y="0.0" width="28" height="28"/>
Expand Down Expand Up @@ -164,14 +164,13 @@
</connections>
</button>
<button hidden="YES" translatesAutoresizingMaskIntoConstraints="NO" id="Avv-iY-qO8" userLabel="Add Button" customClass="MouseOverButton" customModule="DuckDuckGo_Privacy_Browser" customModuleProvider="target">
<rect key="frame" x="0.0" y="0.0" width="28" height="28"/>
<rect key="frame" x="0.0" y="0.0" width="16" height="28"/>
<buttonCell key="cell" type="square" bezelStyle="shadowlessSquare" image="Add" imagePosition="overlaps" alignment="center" imageScaling="proportionallyDown" inset="2" id="7j4-bt-brI">
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
<font key="font" metaFont="system"/>
</buttonCell>
<color key="contentTintColor" name="ButtonColor"/>
<constraints>
<constraint firstAttribute="width" constant="28" id="3yU-AH-lhw"/>
<constraint firstAttribute="height" constant="28" id="yDP-bt-OPj"/>
</constraints>
<userDefinedRuntimeAttributes>
Expand Down
2 changes: 1 addition & 1 deletion DuckDuckGo/TabBar/View/TabBarViewItem.swift
Original file line number Diff line number Diff line change
Expand Up @@ -613,7 +613,7 @@ extension TabBarViewItem: MouseClickViewDelegate {
extension TabBarViewItem {

enum Height: CGFloat {
case standard = 32
case standard = 34
}

enum Width: CGFloat {
Expand Down

0 comments on commit befff3f

Please sign in to comment.