Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • videolan/vlc
  • chouquette/vlc
  • bakiewicz.marek122/vlc
  • devnexen/vlc
  • rohanrajpal/vlc
  • blurrrb/vlc
  • gsoc/gsoc2019/darkapex/vlc
  • b1ue/vlc
  • fkuehne/vlc
  • magsoft/vlc
  • chub/vlc
  • cramiro9/vlc
  • robUx4/vlc
  • rom1v/vlc
  • akshayaky/vlc
  • tmk907/vlc
  • akymaster/vlc
  • govind.sharma/vlc
  • psilokos/vlc
  • xjbeta/vlc
  • jahan/vlc
  • 1480c1/vlc
  • amanchande/vlc
  • aaqib/vlc
  • rist/vlc
  • apol/vlc
  • mindfreeze/vlc
  • alexandre-janniaux/vlc
  • sandsmark/vlc
  • jagannatharjun/vlc
  • gsoc/gsoc2020/matiaslgonzalez/vlc
  • gsoc/gsoc2020/jagannatharjun/vlc
  • mstorsjo/vlc
  • gsoc/gsoc2020/vedenta/vlc
  • gsoc/gsoc2020/arnav-ishaan/vlc
  • gsoc/gsoc2020/andreduong/vlc
  • fuzun/vlc
  • gsoc/gsoc2020/vatsin/vlc
  • gsoc/gsoc2020/sagid/vlc
  • yaron/vlc
  • Phoenix/vlc
  • Garf/vlc
  • ePiratWorkarounds/vlc
  • tguillem/vlc
  • jnqnfe/vlc
  • mdc/vlc
  • Vedaa/vlc
  • rasa/vlc
  • quink/vlc
  • yealo/vlc
  • aleksey_ak/vlc
  • ePirat/vlc
  • ilya.yanok/vlc
  • asenat/vlc
  • m/vlc
  • bunjee/vlc
  • BLumia/vlc
  • sagudev/vlc
  • hamedmonji30/vlc
  • nullgemm/vlc
  • DivyamAhuja/vlc
  • thesamesam/vlc
  • dag7/vlc
  • snehil101/vlc
  • haasn/vlc
  • jbk/vlc
  • ValZapod/vlc
  • mfkl/vlc
  • WangChuan/vlc
  • core1024/vlc
  • GhostVaibhav/vlc
  • dfuhrmann/vlc
  • davide.prade/vlc
  • tmatth/vlc
  • Courmisch/vlc
  • zouya/vlc
  • hpi/vlc
  • EwoutH/vlc
  • aleung27/vlc
  • hengwu0/vlc
  • saladin/vlc
  • ashuio/vlc
  • richselwood/vlc
  • verma16Ayush/vlc
  • chemicalflash/vlc
  • PoignardAzur/vlc
  • huangjieNT/vlc
  • Blake-Haydon/vlc
  • AnuthaDev/vlc
  • gsoc/gsoc2021/mpd/vlc
  • nicolas_lequec/vlc
  • sambassaly/vlc
  • thresh/vlc
  • bonniegong/vlc
  • myaashish/vlc
  • stavros.vagionitis/vlc
  • ileoo/vlc
  • louis-santucci/vlc
  • cchristiansen/vlc
  • sabyasachi07/vlc
  • AbduAmeen/vlc
  • ashishb0410/vlc
  • urbanhusky/vlc
  • davidepietrasanta/vlc
  • riksleutelstad/vlc
  • jeremyVignelles/vlc
  • komh/vlc
  • iamjithinjohn/vlc
  • JohannesKauffmann/vlc2
  • kunglao/vlc
  • natzberg/vlc
  • jill/vlc
  • cwendling/vlc
  • adufou/vlc
  • ErwanAirone/vlc
  • HasinduDilshan10/vlc
  • vagrantc/vlc
  • rafiv/macos-bigsur-icon
  • Aymeriic/vlc
  • saranshg20/vlc
  • metzlove24/vlc
  • linkfanel/vlc
  • Ds886/vlc
  • metehan-arslan/vlc
  • Skantes/vlc
  • kgsandundananjaya96/vlc
  • mitchcapper/vlc
  • advaitgupta/vlc
  • StefanBruens/vlc
  • ratajs/vlc
  • T.M.F.B.3761/vlc
  • m222059/vlc
  • casemerrick/vlc
  • joshuaword2alt/vlc
  • sjwaddy/vlc
  • dima/vlc
  • Ybalrid/vlc
  • umxprime/vlc
  • eschmidt/vlc
  • vannieuwenhuysenmichelle/vlc
  • badcf00d/vlc
  • wesinator/vlc
  • louis/vlc
  • xqq/vlc
  • EmperorYP7/vlc
  • NicoLiam/vlc
  • loveleen/vlc
  • rofferom/vlc
  • rbultje/vlc
  • TheUnamed/vlc
  • pratiksharma341/vlc
  • Saurab17/vlc
  • purist.coder/vlc
  • Shuicheng/vlc
  • mdrrubel292/vlc
  • silverbleu00/vlc
  • metif12/vlc
  • asher-m/vlc
  • jeffk/vlc
  • Brandonbr1/vlc
  • beautyyuyanli/vlc
  • rego21/vlc
  • muyangren907/vlc
  • collectionbylawrencejason/vlc
  • evelez/vlc
  • GSMgeeth/vlc
  • Oneric/vlc
  • TJ5/vlc
  • XuanTung95/vlc
  • darrenjenny21/vlc
  • Trenly/vlc
  • RockyTDR/vlc
  • mjakubowski/vlc
  • caprica/vlc
  • ForteFrankie/vlc
  • seannamiller19/vlc
  • junlon2006/vlc
  • kiwiren6666/vlc
  • iuseiphonexs/vlc
  • fenngtun/vlc
  • Rajdutt999/vlc
  • typx/vlc
  • leon.vitanos/vlc
  • robertogarci0938/vlc
  • gsoc/gsoc2022/luc65r/vlc-mpd
  • skeller/vlc
  • MCJack123/vlc
  • luc65r/vlc-mpd
  • popov895/vlc
  • claucambra/vlc
  • brad/vlc
  • matthewmurua88/vlc
  • Tomas8874/vlc
  • philenotfound/vlc
  • makita-do3/vlc
  • LZXCorp/vlc
  • mar0x/vlc
  • senojetkennedy0102/vlc
  • shaneb243/vlc
  • ahmadbader/vlc
  • rajduttcse26/vlc-audio-filters
  • Juniorzito8415/vlc
  • achernyakov/vlc
  • lucasjetgroup/vlc
  • pupdoggy666/vlc
  • gmde9363/vlc
  • alexnwayne/vlc
  • bahareebrahimi781/vlc
  • hamad633666/vlc
  • umghof3112/vlc
  • joe0199771874/vlc
  • Octocats66666666/vlc
  • jjm_223/vlc
  • btech10110.19/vlc
  • sunnykfc028/vlc-audio-filters
  • loic/vlc
  • nguyenminhducmx1/vlc
  • JanekKrueger/vlc
  • bstubbington2/vlc
  • rcombs/vlc
  • Ordissimo/vlc
  • king7532/vlc
  • noobsauce101/vlc
  • schong0525/vlc
  • myQwil/vlc
  • apisbg91/vlc
  • geeboy0101017/vlc
  • kim.faughey/vlc
  • nurupo/vlc
  • yyusea/vlc
  • 0711235879.khco/vlc
  • ialo/vlc
  • iloveyeye2/vlc
  • gdtdftdqtd/vlc
  • leandroconsiglio/vlc
  • AndyHTML2012/vlc
  • ncz/vlc
  • lucenticus/vlc
  • knr1931/vlc
  • kjoonlee/vlc
  • chandrakant100/vlc-qt
  • johge42/vlc
  • polter/vlc
  • hexchain/vlc
  • Tushwrld/vlc
  • mztea928/vlc
  • jbelloncastro/vlc
  • alvinhochun/vlc
  • ghostpiratecrow/vlc
  • ujjwaltwitx/vlc
  • alexsonarin06/vlc
  • adrianbon76/vlc
  • altsod/vlc
  • damien.lucas44/vlc
  • dmytrivtaisa/vlc
  • utk202/vlc
  • aaxhrj/vlc
  • thomas.hermes/vlc
  • structurenewworldorder/vlc
  • slomo/vlc
  • wantlamy/vlc
  • musc.o3cminc/vlc
  • thebarshablog/vlc
  • kerrick/vlc
  • kratos142518/vlc
  • leogps/vlc
  • vacantron/vlc
  • luna_koly/vlc
  • Ratio2/vlc
  • anuoshemohammad/vlc
  • apsun/vlc
  • aaa1115910/vlc
  • alimotmoyo/vlc
  • Ambossmann/vlc
  • Sam-LearnsToCode/vlc
  • Chilledheart/vlc
  • Labnann/vlc
  • ktcoooot1/vlc
  • mohit-marathe/vlc
  • johnddx/vlc
  • manstabuk/vlc
  • Omar-ahmed314/vlc
  • vineethkm/vlc
  • 9Enemi86/vlc
  • radoslav.m.panteleev/vlc
  • ashishami2002/vlc
  • Corbax/vlc
  • firnasahmed/vlc
  • pelayarmalam4/vlc
  • c0ff330k/vlc
  • shikhindahikar/vlc
  • l342723951/vlc
  • christianschwandner/vlc
  • douniwan5788/vlc
  • 7damian7/vlc
  • ferdnyc/vlc
  • f.ales1/vlc
  • pandagby/vlc
  • BaaBaa/vlc
  • jewe37/vlc
  • w00drow/vlc
  • russelltg/vlc
  • ironicallygod/vlc
  • soumyaDghosh/vlc
  • linzihao1999/vlc
  • deyayush6/vlc
  • mibi88/vlc
  • newabdallah10/vlc
  • jhorbincolombia/vlc
  • rimvihaqueshupto/vlc
  • andrewkhon98/vlc
  • fab78/vlc
  • lapaz17/vlc
  • amanna13/vlc
  • mdakram28/vlc
  • 07jw1980/vlc
  • sohamgupta/vlc
  • Eson-Jia1/vlc
  • Sumou/vlc
  • vikram-kangotra/vlc
  • chalice191/vlc
  • olivercalder/vlc
  • aaasg4001/vlc
  • zipdox/vlc
  • kwizart/vlc
  • Dragon-S/vlc
  • jdemeule/vlc
  • gabriel_lt/vlc
  • locutusofborg/vlc
  • sammirata/vlc-librist
  • another/vlc
  • Benjamin_Loison/vlc
  • ahmedmoselhi/vlc
  • petergaal/vlc
  • huynhsontung/vlc
  • dariusmihut/vlc
  • tvermaashutosh/vlc
  • buti/vlc
  • Niram7777/vlc
  • rohan-here/vlc
  • balaji-sivasakthi/vlc
  • rlindner81/vlc
  • Kakadus/vlc
  • djain/vlc
  • ABBurmeister/vlc
  • craighuggins/vlc
  • orbea/vlc
  • maxos/vlc
  • aakarshmj/vlc
  • kblaschke/vlc
  • ankitm/vlc
  • advait-0/vlc
  • mohak2003/vlc
  • yselkowitz/vlc
  • AZM999/vlc-azm
  • andrey.turkin/vlc
  • Disha-Baghel/vlc
  • nowrep/vlc
  • Apeng/vlc
  • Choucroute_melba/vlc
  • autra/vlc
  • eclipseo/vlc
  • fhuber/vlc
  • olafhering/vlc
  • sdasda7777/vlc
  • 1div0/vlc
  • skosnits/vlc-extended-playlist-support
  • dnicolson/vlc
  • Timshel/vlc
  • octopols/vlc
  • MangalK/vlc
  • nima64/vlc
  • misawai/vlc
  • Alexander-Wilms/vlc
  • Maxime2/vlc-fork-for-visualizer
  • ww/vlc
  • jeske/vlc
  • sgross-emlix/vlc
  • morenonatural/vlc
  • freakingLovesVLC/vlc
  • borisgolovnev/vlc
  • mpromonet/vlc
  • diogo.simao-marques/vlc
  • masstock/vlc
  • pratikpatel8982/vlc
  • hugok79/vlc
  • longervision/vlc
  • abhiudaysurya/vlc
  • rishabhgarg/vlc
  • tumic/vlc
  • cart/vlc
  • shubham442/vlc
  • Aditya692005/vlc
  • sammirata/vlc4
  • syrykh/vlc
  • Vvorcun/macos-new-icon
  • AyaanshC/vlc
  • nasso/vlc
  • Quark/vlc
  • sebastinas/vlc
  • rhstone/vlc
  • talregev/vlc
  • Managor/vlc
403 results
Show changes
Commits on Source (18)
Showing
with 168 additions and 189 deletions
......@@ -1039,6 +1039,7 @@ libqt_plugin_la_QML = \
util/qml/NativeMenu.qml \
util/qml/MLContextMenu.qml \
util/qml/FadeControllerStateGroup.qml \
util/qml/GridSizeHelper.qml \
widgets/qml/LabelExt.qml \
widgets/qml/ActionButtonOverlay.qml \
widgets/qml/ActionButtonPrimary.qml \
......@@ -1061,6 +1062,7 @@ libqt_plugin_la_QML = \
widgets/qml/DragItem.qml \
widgets/qml/DrawerExt.qml \
widgets/qml/ExpandGridView.qml \
widgets/qml/ExpandGridItemView.qml \
widgets/qml/EmptyLabel.qml \
widgets/qml/EmptyLabelButton.qml \
widgets/qml/EmptyLabelHint.qml \
......
......@@ -104,6 +104,8 @@ FocusScope {
RoundImage {
source: artist.cover || VLCStyle.noArtArtist
sourceSize.width: width
sourceSize.height: height
anchors.fill: parent
radius: VLCStyle.cover_normal
}
......
......@@ -35,7 +35,6 @@ Widgets.GridItem {
subtitle: model.main_artist || qsTr("Unknown artist")
pictureWidth: VLCStyle.gridCover_music_width
pictureHeight: VLCStyle.gridCover_music_height
playCoverBorderWidth: VLCStyle.gridCover_music_border
onPlayClicked: {
if ( model.id !== undefined ) {
MediaLib.addAndPlay( model.id )
......
......@@ -93,12 +93,13 @@ MainInterface.MainViewLoader {
Component {
id: gridComponent
MainInterface.MainGridView {
Widgets.ExpandGridItemView {
id: gridView_id
basePictureWidth: VLCStyle.gridCover_music_width
basePictureHeight: VLCStyle.gridCover_music_height
activeFocusOnTab:true
cellWidth: VLCStyle.gridItem_music_width
cellHeight: VLCStyle.gridItem_music_height
headerDelegate: root.header
......@@ -108,6 +109,12 @@ MainInterface.MainViewLoader {
delegate: AudioGridItem {
id: audioGridItem
width: gridView_id.cellWidth;
height: gridView_id.cellHeight;
pictureWidth: gridView_id.maxPictureWidth
pictureHeight: gridView_id.maxPictureHeight
opacity: gridView_id.expandIndex !== -1 && gridView_id.expandIndex !== audioGridItem.index ? .7 : 1
dragItem: albumDragItem
onItemClicked : (modifier) => { gridView_id.leftClickOnItem(modifier, index) }
......@@ -176,10 +183,8 @@ MainInterface.MainViewLoader {
MainInterface.MainTableView {
id: tableView_id
readonly property int _nbCols: VLCStyle.gridColumnsForWidth(tableView_id.availableRowWidth)
property var _modelSmall: [{
size: Math.max(2, tableView_id._nbCols),
weight: 1,
model: ({
criteria: "title",
......@@ -196,7 +201,7 @@ MainInterface.MainViewLoader {
}]
property var _modelMedium: [{
size: 2,
weight: 1,
model: {
criteria: "title",
......@@ -209,7 +214,7 @@ MainInterface.MainViewLoader {
placeHolder: VLCStyle.noArtAlbumCover
}
}, {
size: Math.max(1, tableView_id._nbCols - 3),
weight: 1,
model: {
criteria: "main_artist",
......
......@@ -126,6 +126,8 @@ FocusScope {
source: (root.model && root.model.cover && root.model.cover !== "")
? root.model.cover
: VLCStyle.noArtAlbumCover
sourceSize.width: width
sourceSize.height: height
Widgets.DefaultShadow {
anchors.centerIn: parent
......@@ -366,8 +368,6 @@ FocusScope {
fadingEdge.backgroundColor: headerColor
readonly property int _nbCols: VLCStyle.gridColumnsForWidth(tracks.availableRowWidth)
property Component titleDelegate: Widgets.TableRowDelegate {
id: title
......@@ -435,7 +435,7 @@ FocusScope {
}
sortModel: [{
size: Math.max(tracks._nbCols - 1, 1),
weight: 1,
model: {
criteria: "title",
......
......@@ -81,14 +81,16 @@ MainInterface.MainViewLoader {
Component {
id: gridComponent
MainInterface.MainGridView {
Widgets.ExpandGridItemView {
id: artistGrid
basePictureWidth: VLCStyle.gridCover_music_width
basePictureHeight: VLCStyle.gridCover_music_height
titleTopMargin: VLCStyle.gridItemTitle_topMargin + VLCStyle.margin_xxsmall
selectionModel: root.selectionModel
model: artistModel
focus: true
cellWidth: VLCStyle.colWidth(1)
cellHeight: VLCStyle.gridItem_music_height
headerDelegate: root.header
Navigation.parentItem: root
......@@ -105,19 +107,21 @@ MainInterface.MainViewLoader {
delegate: AudioGridItem {
id: gridItem
width: artistGrid.cellWidth
height: artistGrid.cellHeight
pictureWidth: artistGrid.maxPictureWidth
pictureHeight: artistGrid.maxPictureHeight
pictureRadius: artistGrid.maxPictureWidth
image: model.cover || ""
fallbackImage: VLCStyle.noArtArtistSmall
title: model.name || qsTr("Unknown artist")
subtitle: model.nb_tracks > 1 ? qsTr("%1 songs").arg(model.nb_tracks) : qsTr("%1 song").arg(model.nb_tracks)
pictureRadius: VLCStyle.artistGridCover_radius
pictureHeight: VLCStyle.artistGridCover_radius
pictureWidth: VLCStyle.artistGridCover_radius
playCoverBorderWidth: VLCStyle.dp(3, VLCStyle.scale)
titleMargin: VLCStyle.margin_xlarge
titleTopMargin: artistGrid.titleTopMargin
playIconSize: VLCStyle.play_cover_small
textAlignHCenter: true
width: VLCStyle.colWidth(1)
dragItem: artistsDragItem
onItemClicked: (modifier) => { artistGrid.leftClickOnItem(modifier, index) }
......@@ -142,10 +146,8 @@ MainInterface.MainViewLoader {
MainInterface.MainTableView {
id: artistTable
readonly property int _nbCols: VLCStyle.gridColumnsForWidth(artistTable.availableRowWidth)
property var _modelSmall: [{
size: Math.max(2, artistTable._nbCols),
weight: 1,
model: ({
criteria: "name",
......@@ -162,7 +164,7 @@ MainInterface.MainViewLoader {
}]
property var _modelMedium: [{
size: Math.max(1, artistTable._nbCols - 1),
weight: 1,
model: {
criteria: "name",
......
......@@ -142,23 +142,30 @@ FocusScope {
width: albumsList.width
height: implicitHeight
spacing: VLCStyle.tableView_spacing
spacing: VLCStyle.tableView_spacing - VLCStyle.margin_xxxsmall
Widgets.KeyNavigableListView {
id: albumsList
focus: true
x: VLCStyle.margin_xlarge - VLCStyle.gridItemSelectedBorder
width: root.width - root.rightPadding - x * 2
height: gridHelper.cellHeight + topMargin + bottomMargin + VLCStyle.margin_xxxsmall
height: VLCStyle.gridItem_music_height + topMargin + bottomMargin
width: root.width - root.rightPadding
leftMargin: VLCStyle.gridItemSelectedBorder
rightMargin: leftMargin
leftMargin: VLCStyle.margin_xlarge
topMargin: VLCStyle.gridItemSelectedBorder
bottomMargin: VLCStyle.gridItemSelectedBorder
focus: true
model: albumModel
selectionModel: albumSelectionModel
orientation: ListView.Horizontal
spacing: VLCStyle.column_spacing
buttonMargin: (gridHelper.cellHeight - gridHelper.textHeight - buttonLeft.height) / 2 +
VLCStyle.gridItemSelectedBorder
Navigation.parentItem: root
......@@ -170,20 +177,31 @@ FocusScope {
root.setCurrentItemFocus(Qt.TabFocusReason);
}
Util.GridSizeHelper {
id: gridHelper
availableWidth: albumsList.width
basePictureWidth: VLCStyle.gridCover_music_width
basePictureHeight: VLCStyle.gridCover_music_height
}
delegate: Widgets.GridItem {
id: gridItem
y: selectedBorderWidth
width: gridHelper.cellWidth
height: gridHelper.cellHeight
pictureWidth: gridHelper.maxPictureWidth
pictureHeight: gridHelper.maxPictureHeight
image: model.cover || ""
fallbackImage: VLCStyle.noArtAlbumCover
title: model.title || qsTr("Unknown title")
subtitle: model.release_year || ""
textAlignHCenter: true
x: selectedBorderWidth
y: selectedBorderWidth
pictureWidth: VLCStyle.gridCover_music_width
pictureHeight: VLCStyle.gridCover_music_height
playCoverBorderWidth: VLCStyle.gridCover_music_border
dragItem: albumDragItem
onPlayClicked: play()
......@@ -330,13 +348,14 @@ FocusScope {
Component {
id: gridComponent
MainInterface.MainGridView {
Widgets.ExpandGridItemView {
id: gridView_id
basePictureWidth: VLCStyle.gridCover_music_width
basePictureHeight: VLCStyle.gridCover_music_height
focus: true
activeFocusOnTab:true
cellWidth: VLCStyle.gridItem_music_width
cellHeight: VLCStyle.gridItem_music_height
headerDelegate: root.header
selectionModel: albumSelectionModel
model: albumModel
......@@ -352,6 +371,12 @@ FocusScope {
delegate: AudioGridItem {
id: audioGridItem
width: gridView_id.cellWidth
height: gridView_id.cellHeight
pictureWidth: gridView_id.maxPictureWidth
pictureHeight: gridView_id.maxPictureHeight
opacity: gridView_id.expandIndex !== -1 && gridView_id.expandIndex !== audioGridItem.index ? .7 : 1
dragItem: albumDragItem
......@@ -428,8 +453,6 @@ FocusScope {
MainInterface.MainTableView {
id: tableView_id
readonly property int _nbCols: VLCStyle.gridColumnsForWidth(tableView_id.availableRowWidth)
model: trackModel
onActionForSelection: (selection) => {
......@@ -441,7 +464,7 @@ FocusScope {
rowHeight: VLCStyle.tableCoverRow_height
property var _modelSmall: [{
size: Math.max(2, tableView_id._nbCols),
weight: 1,
model: {
criteria: "title",
......@@ -456,7 +479,7 @@ FocusScope {
}]
property var _modelMedium: [{
size: 2,
weight: 1,
model: {
criteria: "title",
......@@ -467,7 +490,7 @@ FocusScope {
colDelegate: tableColumns.titleDelegate
}
}, {
size: Math.max(1, tableView_id._nbCols - 3),
weight: 1,
model: {
criteria: "album_title",
......
......@@ -166,6 +166,8 @@ T.ItemDelegate {
source: (model.cover) ? model.cover
: VLCStyle.noArtArtistSmall
sourceSize.width: width
sourceSize.height: height
Layout.alignment: Qt.AlignLeft | Qt.AlignVCenter
......
......@@ -118,8 +118,13 @@ MainInterface.MainViewLoader {
/* Grid View */
Component {
id: gridComponent
MainInterface.MainGridView {
Widgets.ExpandGridItemView {
id: gridView_id
basePictureWidth: VLCStyle.gridCover_video_width
basePictureHeight: VLCStyle.gridCover_video_width / 2
titleHeight: 0
subtitleHeight: 0
selectionModel: root.selectionModel
model: genreModel
......@@ -132,17 +137,17 @@ MainInterface.MainViewLoader {
property var model: ({})
property int index: -1
width: VLCStyle.colWidth(2)
height: width / 2
pictureWidth: width
pictureHeight: height
width: gridView_id.cellWidth
height: gridView_id.cellHeight
pictureWidth: gridView_id.maxPictureWidth
pictureHeight: gridView_id.maxPictureHeight
image: model.cover || ""
cacheImage: true // for this view, we generate custom covers, cache it
fallbackImage: VLCStyle.noArtAlbumCover
playCoverBorderWidth: VLCStyle.dp(3, VLCStyle.scale)
dragItem: genreDragItem
onItemDoubleClicked: root.showAlbumView(model.id, model.name, Qt.MouseFocusReason)
......@@ -199,9 +204,6 @@ MainInterface.MainViewLoader {
focus: true
cellWidth: VLCStyle.colWidth(2)
cellHeight: cellWidth / 2
onActionAtIndex: (index) => { _actionAtIndex(index) }
Navigation.parentItem: root
......@@ -214,10 +216,8 @@ MainInterface.MainViewLoader {
MainInterface.MainTableView {
id: tableView_id
property int _nbCols: VLCStyle.gridColumnsForWidth(availableRowWidth)
property var _modelSmall: [{
size: Math.max(2, tableView_id._nbCols),
weight: 1,
model: {
criteria: "name",
......@@ -232,26 +232,16 @@ MainInterface.MainViewLoader {
}]
property var _modelMedium: [{
size: 1,
weight: 1,
model: {
criteria: "cover",
text: qsTr("Cover"),
criteria: "name",
isSortable: false,
text: qsTr("Name"),
headerDelegate: tableColumns.titleHeaderDelegate,
colDelegate: tableColumns.titleDelegate
}
}, {
size: Math.max(1, _nbCols - 2),
model: {
criteria: "name",
text: qsTr("Name")
}
}, {
size: 1,
......@@ -293,8 +283,7 @@ MainInterface.MainViewLoader {
Widgets.MLTableColumns {
id: tableColumns
showTitleText: (tableView_id.sortModel === tableView_id._modelSmall)
showCriterias: showTitleText
showCriterias: (tableView_id.sortModel === tableView_id._modelSmall)
titleCover_height: VLCStyle.listAlbumCover_height
titleCover_width: VLCStyle.listAlbumCover_width
......
......@@ -42,11 +42,6 @@ Widgets.KeyNavigableTableView {
property alias parentId: rootmodel.parentId
// Private
property int _nbCols: VLCStyle.gridColumnsForWidth(availableRowWidth)
readonly property int _sizeA: Math.floor((_nbCols - 3) / 3)
readonly property int _sizeB: Math.floor((_nbCols - 2) / 2)
property var _lineTitle: ({
criteria: "title",
......@@ -104,41 +99,41 @@ Widgets.KeyNavigableTableView {
})
property var _modelLarge: [{
size: _sizeA,
weight: 1,
model: _lineTitle
}, {
size: _sizeA,
weight: 1,
model: _lineAlbum
}, {
size: _sizeA,
weight: 1,
model: _lineArtist
}, {
size: 1,
model: _lineDuration
model: _lineTrack
}, {
size: 1,
model: _lineTrack
model: _lineDisc
}, {
size: 1,
model: _lineDisc
model: _lineDuration
}]
property var _modelMedium: [{
size: _sizeB,
weight: 1,
model: _lineTitle
}, {
size: _sizeB,
weight: 1,
model: _lineAlbum
}, {
size: 1,
weight: 1,
model: _lineArtist
}, {
......@@ -148,7 +143,7 @@ Widgets.KeyNavigableTableView {
}]
property var _modelSmall: [{
size: Math.max(2, _nbCols),
weight: 1,
model: ({
criteria: "title",
......
......@@ -35,8 +35,6 @@ MainInterface.MainTableView {
// Properties
//---------------------------------------------------------------------------------------------
readonly property int columns: VLCStyle.gridColumnsForWidth(root.availableRowWidth)
property bool isMusic
//---------------------------------------------------------------------------------------------
......@@ -47,7 +45,7 @@ MainInterface.MainTableView {
property bool _before: true
property var _modelSmall: [{
size: Math.max(2, columns),
weight: 1,
model: {
criteria: "title",
......@@ -66,32 +64,20 @@ MainInterface.MainTableView {
}]
property var _modelMedium: [{
size: 1,
weight: 1,
model: {
criteria: "thumbnail",
criteria: "title",
text: qsTr("Cover"),
text: qsTr("Title"),
isSortable: false,
type: "image",
headerDelegate: table.titleHeaderDelegate,
colDelegate : table.titleDelegate,
placeHolder: VLCStyle.noArtAlbumCover
}
}, {
size: Math.max(1, columns - 2),
model: {
criteria: "title",
text: qsTr("Title"),
isSortable: false
}
}, {
size: 1,
......@@ -260,8 +246,7 @@ MainInterface.MainTableView {
titleCover_radius: isMusic ? VLCStyle.trackListAlbumCover_radius
: VLCStyle.listAlbumCover_radius
showTitleText: (root.sortModel === root._modelSmall)
showCriterias: showTitleText
showCriterias: (root.sortModel === root._modelSmall)
criteriaCover: "thumbnail"
......
......@@ -55,18 +55,6 @@ MainInterface.MainViewLoader {
//---------------------------------------------------------------------------------------------
// Private
property int _width: (isMusic) ? VLCStyle.gridItem_music_width
: VLCStyle.gridItem_video_width
property int _height: (isMusic) ? VLCStyle.gridItem_music_height
: VLCStyle.gridItem_video_height
property int _widthCover: (isMusic) ? VLCStyle.gridCover_music_width
: VLCStyle.gridCover_video_width
property int _heightCover: (isMusic) ? VLCStyle.gridCover_music_height
: VLCStyle.gridCover_video_height
property string _placeHolder: (isMusic) ? VLCStyle.noArtAlbumCover
: VLCStyle.noArtVideoCover
......@@ -252,14 +240,14 @@ MainInterface.MainViewLoader {
Component {
id: grid
MainInterface.MainGridView {
Widgets.ExpandGridItemView {
id: gridView
//-------------------------------------------------------------------------------------
// Settings
cellWidth : _width
cellHeight: _height
basePictureWidth: isMusic ? VLCStyle.gridCover_music_width : VLCStyle.gridCover_video_width
basePictureHeight: isMusic ? VLCStyle.gridCover_music_height : VLCStyle.gridCover_video_height
model: root.model
......@@ -280,8 +268,11 @@ MainInterface.MainViewLoader {
//---------------------------------------------------------------------------------
// Settings
pictureWidth : _widthCover
pictureHeight: _heightCover
width: gridView.cellWidth;
height: gridView.cellHeight;
pictureWidth : gridView.maxPictureWidth
pictureHeight: gridView.maxPictureHeight
title: (model.name) ? model.name
: qsTr("Unknown title")
......@@ -355,10 +346,8 @@ MainInterface.MainViewLoader {
//-------------------------------------------------------------------------------------
// Properties
property int _columns: Math.max(1, VLCStyle.gridColumnsForWidth(availableRowWidth) - 2)
property var _modelSmall: [{
size: Math.max(2, _columns),
weight: 1,
model: {
criteria: "name",
......@@ -373,26 +362,16 @@ MainInterface.MainViewLoader {
}]
property var _modelMedium: [{
size: 1,
weight: 1,
model: {
criteria: "thumbnail",
text: qsTr("Cover"),
criteria: "name",
isSortable: false,
text: qsTr("Name"),
headerDelegate: columns.titleHeaderDelegate,
colDelegate : columns.titleDelegate
}
}, {
size: _columns,
model: {
criteria: "name",
text: qsTr("Name")
}
}, {
size: 1,
......@@ -454,8 +433,7 @@ MainInterface.MainViewLoader {
Widgets.TableColumns {
id: columns
showTitleText: (tableView.sortModel === tableView._modelSmall)
showCriterias: showTitleText
showCriterias: (tableView.sortModel === tableView._modelSmall)
criteriaCover: "thumbnail"
......
......@@ -37,8 +37,6 @@ Widgets.KeyNavigableTableView {
property alias sortOrder: urlModel.sortOrder
property alias sortCriteria: urlModel.sortCriteria
readonly property int _nbCols: VLCStyle.gridColumnsForWidth(
listView_id.availableRowWidth)
property Component urlHeaderDelegate: Widgets.TableHeaderDelegate {
Widgets.IconLabel {
anchors.fill: parent
......@@ -54,7 +52,7 @@ Widgets.KeyNavigableTableView {
model: urlModel
sortModel: [{
size: Math.max(listView_id._nbCols - 1, 1),
weight: 1,
model: {
criteria: "url",
......
......@@ -268,6 +268,9 @@ VideoAll {
nbItemPerRow: root.currentItem?.nbItemPerRow ?? 0
allVideosContentLeftMargin: root.currentItem?.contentLeftMargin ?? 0
allVideosContentRightMargin: root.currentItem?.contentRightMargin ?? 0
subtitleText: (root.model && root.model.count > 0) ? qsTr("Videos") : ""
Navigation.parentItem: root
......
......@@ -24,12 +24,11 @@ import QtQml.Models
import org.videolan.vlc 0.1
import org.videolan.medialib 0.1
import "qrc:///main/" as MainInterface
import "qrc:///util" as Util
import "qrc:///widgets/" as Widgets
import "qrc:///style/"
MainInterface.MainGridView {
Widgets.ExpandGridItemView {
id: gridView
// Properties
......@@ -44,8 +43,8 @@ MainInterface.MainGridView {
// Settings
cellWidth : VLCStyle.gridItem_video_width
cellHeight: VLCStyle.gridItem_video_height
basePictureWidth: VLCStyle.gridCover_video_width
basePictureHeight: VLCStyle.gridCover_video_height
activeFocusOnTab: true
......@@ -93,6 +92,12 @@ MainInterface.MainGridView {
// Settings
width: gridView.cellWidth
height: gridView.cellHeight
pictureWidth: gridView.maxPictureWidth
pictureHeight: gridView.maxPictureHeight
opacity: (gridView.expandIndex !== -1
&&
gridView.expandIndex !== gridItem.index) ? 0.7 : 1
......
......@@ -45,8 +45,6 @@ Widgets.GridItem {
subtitle: model?.duration?.formatHMS() ?? ""
pictureWidth: VLCStyle.gridCover_video_width
pictureHeight: VLCStyle.gridCover_video_height
playCoverBorderWidth: VLCStyle.gridCover_video_border
titleMargin: VLCStyle.margin_xxsmall
pictureOverlay: Item {
width: root.pictureWidth
......
......@@ -115,6 +115,8 @@ FocusScope {
anchors.fill: parent
source: model.thumbnail || VLCStyle.noArtVideoCover
sourceSize.width: width
sourceSize.height: height
radius: VLCStyle.gridCover_radius
Widgets.DefaultShadow {
......
......@@ -42,10 +42,8 @@ MainInterface.MainTableView {
//---------------------------------------------------------------------------------------------
// Private
readonly property int _nbCols: VLCStyle.gridColumnsForWidth(availableRowWidth)
property var _modelSmall: [{
size: Math.max(2, _nbCols),
weight: 1,
model: ({
criteria: mainCriteria,
......@@ -64,33 +62,19 @@ MainInterface.MainTableView {
}]
property var _modelMedium: [{
size: 1,
weight: 1,
model: ({
type: "image",
criteria: "thumbnail",
text: qsTr("Cover"),
isSortable: false,
criteria: mainCriteria,
showSection: "",
showSection: "title",
placeHolder: VLCStyle.noArtVideoCover,
text: qsTr("Title"),
headerDelegate: tableColumns.titleHeaderDelegate,
colDelegate : tableColumns.titleDelegate
})
}, {
size: Math.max(1, _nbCols - 2),
model: ({
criteria: mainCriteria,
showSection: "title",
colDelegate : tableColumns.titleDelegate,
text: qsTr("Title")
placeHolder: VLCStyle.noArtVideoCover
})
}, {
size: 1,
......@@ -124,8 +108,7 @@ MainInterface.MainTableView {
Widgets.MLTableColumns {
id: tableColumns
showTitleText: (listView_id.sortModel === listView_id._modelSmall)
showCriterias: showTitleText
showCriterias: (listView_id.sortModel === listView_id._modelSmall)
criteriaCover: "thumbnail"
......
......@@ -41,6 +41,9 @@ FocusScope {
property int rightPadding: VLCStyle.margin_xsmall
property int nbItemPerRow
property int allVideosContentLeftMargin
property int allVideosContentRightMargin
property alias model: recentModel
......@@ -149,9 +152,11 @@ FocusScope {
view: root
leftPadding: view.currentItem?.contentLeftMargin ?? 0
topPadding: MainCtx.gridView ? VLCStyle.gridView_spacing + VLCStyle.margin_xsmall + VLCStyle.margin_xxxsmall
: VLCStyle.tableView_spacing
leftPadding: allVideosContentLeftMargin
rightPadding: allVideosContentRightMargin
topPadding: recentModel.count > 0 ? (MainCtx.gridView ? VLCStyle.gridView_spacing :
VLCStyle.tableView_spacing)
: 0
text: view.title
}
......
......@@ -23,7 +23,6 @@ import QtQuick
import org.videolan.vlc 0.1
import "qrc:///style/"
import "qrc:///main/" as MainInterface
import "qrc:///widgets/" as Widgets
import "qrc:///util/" as Util
......@@ -182,16 +181,18 @@ FocusScope {
Component {
id: grid
Widgets.ExpandGridView {
Widgets.ExpandGridItemView {
id: gridView
basePictureWidth: VLCStyle.gridCover_network_width
basePictureHeight: VLCStyle.gridCover_network_height
maxNbItemPerRow: 12
readonly property int maximumCount: (root.maximumRows === -1)
? -1
: root.maximumRows * nbItemPerRow
cellWidth: VLCStyle.gridItem_network_width
cellHeight: VLCStyle.gridItem_network_height
displayMarginEnd: root.displayMarginEnd
model: root.model
......@@ -207,6 +208,12 @@ FocusScope {
onActionAtIndex: (index) => { root.onAction(index) }
delegate: NetworkGridItem {
width: gridView.cellWidth;
height: gridView.cellHeight;
pictureWidth: gridView.maxPictureWidth
pictureHeight: gridView.maxPictureHeight
onItemClicked: (modifier) => { root.onClicked(model, index, modifier) }
onItemDoubleClicked: root.onDoubleClicked(model, index)
......@@ -228,12 +235,8 @@ FocusScope {
readonly property int nbItemPerRow: 1
readonly property int _nbCols: VLCStyle.gridColumnsForWidth(availableRowWidth)
readonly property int _size: (_nbCols - 1) / 2
property var _modelSmall: [{
size: Math.max(2, _nbCols),
weight: 1,
model: ({
criteria: "name",
......@@ -263,7 +266,7 @@ FocusScope {
colDelegate: artworkColumn
}
}, {
size: _size,
weight: 1,
model: {
criteria: "name",
......@@ -271,7 +274,7 @@ FocusScope {
text: qsTr("Name")
}
}, {
size: Math.max(_nbCols - _size - 1, 1),
weight: 1,
model: {
criteria: "mrl",
......