<commit_before>#include "fuhahaEngine.h"
#include "./pageTest2.h"

// ----------------------------------------------------------------
// ----------------------------------------------------------------
// ----------------------------------------------------------------

// 構造体実体
struct pageTest2PartsPagerImplement{
	struct pageTest2PartsPager super;
	struct pageTest2CartridgePage *page;
	struct pageTest2Status *stat;

	int pageW;
	struct{
		struct engineLayoutView *viewPage;
		struct engineLayoutViewPartsButtonBox *viewButton;
	} pages[3];
};

// ----------------------------------------------------------------

// 初期化
static void init(struct pageTest2PartsPagerImplement *this){
	engineLayoutViewUtilInit((struct engineLayoutView*)this);

	// ページャー作成
	this->stat->viewPager = engineLayoutViewPartsSwipePagerCreate();
	engineLayoutViewUtilPositionSetLtRtTpBm((struct engineLayoutView*)this->stat->viewPager, 0, 0, 40, 0);
	engineLayoutViewUtilFamilyAdd((struct engineLayoutView*)this, (struct engineLayoutView*)this->stat->viewPager);
	engineLayoutViewUtilGraphicObjectConnect((struct engineLayoutView*)this, (struct engineLayoutView*)this->stat->viewPager);

	// ページ作成
	this->pages[0].viewPage = (struct engineLayoutView*)pageTest2PartsPagerPage1Create(this->stat);
	this->pages[1].viewPage = (struct engineLayoutView*)pageTest2PartsPagerPage2Create(this->stat);
	this->pages[2].viewPage = (struct engineLayoutView*)pageTest2PartsPagerPage3Create(this->stat);
	// ボタン作成
	this->pages[0].viewButton = engineLayoutViewPartsButtonBoxCreateText("1");
	this->pages[1].viewButton = engineLayoutViewPartsButtonBoxCreateText("2");
	this->pages[2].viewButton = engineLayoutViewPartsButtonBoxCreateText("3");
	for(int i = 0; i < (int)(sizeof(this->pages) / sizeof(*this->pages)); i++){
		// ページ設定
		engineLayoutViewUtilFamilyAdd((struct engineLayoutView*)this->stat->viewPager->viewInner, (struct engineLayoutView*)this->pages[i].viewPage);
		engineLayoutViewUtilGraphicObjectConnect((struct engineLayoutView*)this->stat->viewPager->viewInner, (struct engineLayoutView*)this->pages[i].viewPage);
		// ボタン設定
		engineLayoutViewUtilPositionSetTop((struct engineLayoutView*)this->pages[i].viewButton, 0);
		engineLayoutViewUtilPositionSetHeightValue((struct engineLayoutView*)this->pages[i].viewButton, 40);
		engineLayoutViewUtilFamilyAdd((struct engineLayoutView*)this, (struct engineLayoutView*)this->pages[i].viewButton);
		engineLayoutViewUtilGraphicObjectConnect((struct engineLayoutView*)this, (struct engineLayoutView*)this->pages[i].viewButton);
	}
}

// ----------------------------------------------------------------

// タッチ処理
static bool touch(struct pageTest2PartsPagerImplement *this, int touchIndex, double x, double y, bool dn, bool mv, bool isCancel){
	bool isActive = false;
	bool isActiveChild = engineLayoutViewUtilChildrenTouch((struct engineLayoutView*)this, touchIndex, x, y, dn, mv, isCancel || isActive); isActive = isActiveChild || isActive;
	bool isActiveLocal = engineLayoutViewUtilInteractTouch((struct engineLayoutView*)this, touchIndex, x, y, dn, mv, isCancel || isActive); isActive = isActiveLocal || isActive;
	return isActive;<commit_msg>ページャーマスク<commit_after>#include "fuhahaEngine.h"
#include "./pageTest2.h"

// ----------------------------------------------------------------
// ----------------------------------------------------------------
// ----------------------------------------------------------------

// 構造体実体
struct pageTest2PartsPagerImplement{
	struct pageTest2PartsPager super;
	struct pageTest2CartridgePage *page;
	struct pageTest2Status *stat;

	int pageW;
	struct{
		struct engineLayoutView *viewPage;
		struct engineLayoutViewPartsButtonBox *viewButton;
	} pages[3];
};

// ----------------------------------------------------------------

// 初期化
static void init(struct pageTest2PartsPagerImplement *this){
	engineLayoutViewUtilInit((struct engineLayoutView*)this);

	// ページャーマスク作成
	struct engineLayoutViewPartsMaskRect *viewPagerMask = engineLayoutViewPartsMaskRectCreate();
	engineLayoutViewUtilPositionSetLtRtTpBm((struct engineLayoutView*)viewPagerMask, 0, 0, 40, 0);
	engineLayoutViewUtilFamilyAdd((struct engineLayoutView*)this, (struct engineLayoutView*)viewPagerMask);
	engineLayoutViewUtilGraphicObjectConnect((struct engineLayoutView*)this, (struct engineLayoutView*)viewPagerMask);
	// ページャー作成
	this->stat->viewPager = engineLayoutViewPartsSwipePagerCreate();
	engineLayoutViewUtilFamilyAdd((struct engineLayoutView*)viewPagerMask, (struct engineLayoutView*)this->stat->viewPager);
	engineLayoutViewUtilGraphicObjectConnect((struct engineLayoutView*)viewPagerMask, (struct engineLayoutView*)this->stat->viewPager);

	// ページ作成
	this->pages[0].viewPage = (struct engineLayoutView*)pageTest2PartsPagerPage1Create(this->stat);
	this->pages[1].viewPage = (struct engineLayoutView*)pageTest2PartsPagerPage2Create(this->stat);
	this->pages[2].viewPage = (struct engineLayoutView*)pageTest2PartsPagerPage3Create(this->stat);
	// ボタン作成
	this->pages[0].viewButton = engineLayoutViewPartsButtonBoxCreateText("1");
	this->pages[1].viewButton = engineLayoutViewPartsButtonBoxCreateText("2");
	this->pages[2].viewButton = engineLayoutViewPartsButtonBoxCreateText("3");
	for(int i = 0; i < (int)(sizeof(this->pages) / sizeof(*this->pages)); i++){
		// ページ設定
		engineLayoutViewUtilFamilyAdd((struct engineLayoutView*)this->stat->viewPager->viewInner, (struct engineLayoutView*)this->pages[i].viewPage);
		engineLayoutViewUtilGraphicObjectConnect((struct engineLayoutView*)this->stat->viewPager->viewInner, (struct engineLayoutView*)this->pages[i].viewPage);
		// ボタン設定
		engineLayoutViewUtilPositionSetTop((struct engineLayoutView*)this->pages[i].viewButton, 0);
		engineLayoutViewUtilPositionSetHeightValue((struct engineLayoutView*)this->pages[i].viewButton, 40);
		engineLayoutViewUtilFamilyAdd((struct engineLayoutView*)this, (struct engineLayoutView*)this->pages[i].viewButton);
		engineLayoutViewUtilGraphicObjectConnect((struct engineLayoutView*)this, (struct engineLayoutView*)this->pages[i].viewButton);
	}
}

// ----------------------------------------------------------------

// タッチ処理
static bool touch(struct pageTest2PartsPagerImplement *this, int touchIndex, double x, double y, bool dn, bool mv, bool isCancel){
	bool isActive = false;
	bool isActiveChild = engineLayoutViewUtilChildrenTouch((struct engineLayoutView*)this, touchIndex, x, y, dn, mv, isCancel || isActive); isActive = isActiveChild || isActive;
	bool isActiveLocal = engineLayoutViewUtilInteractTouch((struct engineLayoutView*)this, touchIndex, x, y, dn, mv, isCancel || isActive); isActive = isActiveLocal || isActive;
	return isActive;
{'fraction_non_alphanumeric': 0.20857699805068225, 'fraction_numerical': 0.009596641175588543, 'mean_word_length': 4.138674884437596, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 63, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4259820', 'n_tokens_mistral': 1948, 'n_tokens_neox': 1918, 'n_words': 312}