parent
355c5b75c8
commit
10805725a7
|
@ -796,16 +796,15 @@ export default class Timeline extends Mixins(GlobalMixin, UserConfig) {
|
||||||
this.loadedDays.add(dayId);
|
this.loadedDays.add(dayId);
|
||||||
this.sizedDays.add(dayId);
|
this.sizedDays.add(dayId);
|
||||||
|
|
||||||
// Filter out items we don't want to show at all
|
|
||||||
// Note: flags are not converted yet
|
|
||||||
if (!this.config_showHidden) {
|
|
||||||
// Hidden folders
|
|
||||||
data = data.filter((p) => !(p.isfolder && (<IFolder>p).name.startsWith('.')));
|
|
||||||
}
|
|
||||||
|
|
||||||
// Convert server flags to bitflags
|
// Convert server flags to bitflags
|
||||||
data.forEach(utils.convertFlags);
|
data.forEach(utils.convertFlags);
|
||||||
|
|
||||||
|
// Filter out items we don't want to show at all
|
||||||
|
if (!this.config_showHidden) {
|
||||||
|
// Hidden folders
|
||||||
|
data = data.filter((p) => !((p.flag & this.c.FLAG_IS_FOLDER) && (<IFolder>p).name.startsWith('.')));
|
||||||
|
}
|
||||||
|
|
||||||
// Set and make reactive
|
// Set and make reactive
|
||||||
day.count = data.length;
|
day.count = data.length;
|
||||||
day.detail = data;
|
day.detail = data;
|
||||||
|
@ -895,10 +894,7 @@ export default class Timeline extends Mixins(GlobalMixin, UserConfig) {
|
||||||
|
|
||||||
// Add the photo to the row
|
// Add the photo to the row
|
||||||
const photo = data[dataIdx];
|
const photo = data[dataIdx];
|
||||||
if (typeof photo.flag === "undefined") {
|
photo.d = day; // backref to day
|
||||||
photo.flag = 0; // flags
|
|
||||||
photo.d = day; // backref to day
|
|
||||||
}
|
|
||||||
|
|
||||||
// Get aspect ratio
|
// Get aspect ratio
|
||||||
const setPos = () => {
|
const setPos = () => {
|
||||||
|
|
|
@ -149,6 +149,10 @@ export function randomSubarray(arr: any[], size: number) {
|
||||||
* @param photo Photo to process
|
* @param photo Photo to process
|
||||||
*/
|
*/
|
||||||
export function convertFlags(photo: IPhoto) {
|
export function convertFlags(photo: IPhoto) {
|
||||||
|
if (typeof photo.flag === "undefined") {
|
||||||
|
photo.flag = 0; // flags
|
||||||
|
}
|
||||||
|
|
||||||
if (photo.isvideo) {
|
if (photo.isvideo) {
|
||||||
photo.flag |= constants.c.FLAG_IS_VIDEO;
|
photo.flag |= constants.c.FLAG_IS_VIDEO;
|
||||||
delete photo.isvideo;
|
delete photo.isvideo;
|
||||||
|
|
Loading…
Reference in New Issue