Skip to content

Commit

Permalink
画像から続きを描いた時にもレイヤー情報を保持。続きを描く時の動画を表示しないの表示の制御方法を変更。
Browse files Browse the repository at this point in the history
  • Loading branch information
satopian committed Dec 11, 2024
1 parent 1d4dd83 commit f67b0b1
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 13 deletions.
2 changes: 2 additions & 0 deletions petitnote/app/neo/neo.css
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
position: relative;
height: 100%;
margin: auto;
min-width: 397px;
/* 300px相当の最低幅 */
}

.NEO #toolsWrapper {
Expand Down
12 changes: 11 additions & 1 deletion petitnote/app/neo/neo.js
Original file line number Diff line number Diff line change
Expand Up @@ -1261,6 +1261,15 @@ Neo.submit = function (board, blob, thumbnail, thumbnail2) {
Neo.submitButton.enable();
return alert(text.replace(/^error\n/m, ""));
}
if (text !== "ok") {
Neo.submitButton.enable();
return alert(
errorMessage +
Neo.translate(
"投稿に失敗。時間を置いて再度投稿してみてください。"
)
);
}
var exitURL = Neo.getAbsoluteURL(board, Neo.config.url_exit);
var responseURL = text.replace(/&/g, "&");

Expand Down Expand Up @@ -1318,6 +1327,7 @@ Neo.submit = function (board, blob, thumbnail, thumbnail2) {
);

if (!isConfirmed) {
Neo.submitButton.enable();
console.log("中止しました。");
return; // ユーザーが続行しない場合、処理を中断
}
Expand Down Expand Up @@ -4931,7 +4941,7 @@ Neo.DrawToolBase.prototype.freeHandUpMoveHandler = function (oe) {
};

Neo.DrawToolBase.prototype.drawCursor = function (oe) {
// if (oe.lineWidth <= 8) return;
// if (oe.lineWidth <= 8) return;
var mx = oe.mouseX;
var my = oe.mouseY;
var d = oe.lineWidth;
Expand Down
8 changes: 3 additions & 5 deletions petitnote/index.php
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<?php
//Petit Note (c)さとぴあ @satopian 2021-2024
//1スレッド1ログファイル形式のスレッド式画像掲示板
$petit_ver='v1.63.3';
$petit_lot='lot.20241210';
$petit_ver='v1.63.5';
$petit_lot='lot.20241211';

$lang = ($http_langs = isset($_SERVER['HTTP_ACCEPT_LANGUAGE']) ? $_SERVER['HTTP_ACCEPT_LANGUAGE'] : '')
? explode( ',', $http_langs )[0] : '';
Expand Down Expand Up @@ -756,7 +756,6 @@ function paint(){
$pchfile='';
$img_chi='';
$img_klecks='';
$anime=true;
$rep=false;
$paintmode='paintcom';

Expand Down Expand Up @@ -809,7 +808,6 @@ function paint(){
thumbnail_gd::thumb(TEMP_DIR,$pchup,$time,$max_px,$max_px,['toolarge'=>true]);
list($picw,$pich) = getimagesize($pchup);
$imgfile = $pchup;
$anime = false;
}else{
safe_unlink($pchup);
return error($en? 'This file is an unsupported format.':'対応していないファイル形式です。');
Expand Down Expand Up @@ -844,7 +842,6 @@ function paint(){
}

$imgfile = IMG_DIR.$imgfile;
$anime= true;//常にtrue

if($ctype=='img'){//画像から続き
if($_pch_ext==='.chi'){
Expand Down Expand Up @@ -926,6 +923,7 @@ function paint(){
case 'neo'://PaintBBS NEO

$tool='neo';
$anime= true;//常にtrue
$appw = $picw + 150;//NEOの幅
$apph = $pich + 172;//NEOの高さ
$appw = max($appw,450);//最低幅
Expand Down
17 changes: 10 additions & 7 deletions petitnote/template/basic/continue.html
Original file line number Diff line number Diff line change
Expand Up @@ -154,18 +154,21 @@ <h1 class="title"><a href="./"><?=h($boardname)?></a></h1>
const paint_select = document.getElementById('paint_select');
const hideAnimation = document.getElementById('span_hide_animation');

function toggleHideAnimation(isNeo) {
const toggleHideAnimation = (isNeo) => {
if (hideAnimation) {
hideAnimation.style.display = isNeo ? "inline-block" : "none";
}
}
// セレクトメニューの変更イベント
paint_select.addEventListener('change', (e) => {
toggleHideAnimation(e.target.value==='neo');
<?php if($select_app):?>
document.addEventListener('DOMContentLoaded', () => {
// セレクトメニューの変更イベント
paint_select.addEventListener('change', (e) => {
toggleHideAnimation(e.target.value==='neo');
});
// 初期値の設定を反映
toggleHideAnimation(paint_select.value==='neo');
});

// 初期値の設定を反映
toggleHideAnimation(paint_select.value==='neo');
<?php endif;?>
</script>
<div id="bottom"></div>
<div id="page_top"><a class="icon-angles-up-solid"></a></div>
Expand Down

0 comments on commit f67b0b1

Please sign in to comment.