Skip to content

Instantly share code, notes, and snippets.

@marlonwanger
marlonwanger / Aula06.txt
Created October 6, 2022 22:50
Aula 06 Codes
.binary-image {
width: 96px !important;
border-radius: 50%
}
protected string getAppearenceBackground() {
return (Utility.FixValue<string>(PageProvider.MainProvider.DataProvider.Item["APPEARENCE_BACKGROUND_COLOR"].GetValue())).ToString().Replace(double.NaN.ToString(), "");
}
protected string getAppearenceBackgroundFontColor() {
@marlonwanger
marlonwanger / gvinci.cs
Created March 31, 2021 23:42
OnloadCompleted
var putFull = (PageState == FormStateEnum.Navigation);
if (!this.IsPostBack)
{
ClientScript.RegisterStartupScript(this.GetType(), "AdjustFileUploader", string.Format("<script>setTimeout(\"AdjustFileUploader('{0}');\", 100);</script>", putFull.ToString()));
}
else
{
AjaxPanel.ResponseScripts.Add(string.Format("setTimeout(\"AdjustFileUploader('{0}');\", 100);", putFull.ToString()));
}
@marlonwanger
marlonwanger / Fix.js
Created March 31, 2021 23:37
Fixcss Fileuploader.
function AdjustFileUploader(putFull) {
var j$ = jQuery.noConflict();
if (putFull.toLowerCase() == "true") {
j$("#GMultiMedia1_ImagePanel").addClass("full");
} else {
j$("#GMultiMedia1_ImagePanel").removeClass("full");
}
}
@marlonwanger
marlonwanger / Fileuploader.css
Created March 31, 2021 23:32
Fileuploader.css Final
.NameLabel {
display: none !important;
}
#GMultiMedia1_BorderPanel {
border-color: black;
border-style: solid;
border-width: 1px;
border-radius: 10px;
padding-top: 15px;
@marlonwanger
marlonwanger / Fileuploader.html
Created March 31, 2021 22:59
Fileuploader HTML
<div
id="GMultiMedia1_BorderPanel"
style="position: relative; top: 0px; left: 0px; width: 100%; height: 270px"
>
<div id="GMultiMedia1_ImagePanel" style="
border-width: 1px;
border-style: solid;
text-align: center;
position: relative;
top: 0px;
@marlonwanger
marlonwanger / LoadingIframe.js
Created March 29, 2021 22:39
LoadingIframe.js Final code
function LoadingIFrame(IFrameElement, IFrameLoadingElement) {
var $j = jQuery.noConflict();
$j(document).ready(function () {
var iframe = document.querySelector("#" + IFrameElement);
var image = document.querySelector("#" + IFrameLoadingElement);
new MutationObserver((mutations) => {
mutations.some((mutation) => {
if (
@marlonwanger
marlonwanger / LoadingIframe.js
Created March 29, 2021 22:31
LoadingIframeSemi
function LoadingIFrame(IFrameElement, IFrameLoadingElement) {
var $j = jQuery.noConflict();
$j(document).ready(function () {
var iframe = document.querySelector('#' + IFrameElement);
var image = document.querySelector('#' + IFrameLoadingElement);
new MutationObserver((mutations) => {
mutations.some((mutation) => {
if (mutation.type === 'attributes' && mutation.attributeName === 'src') {
new MutationObserver((mutations) => {
mutations.some((mutation) => {
if (mutation.type === 'attributes' && mutation.attributeName === 'src') {
iframe.parentElement.style.display = 'none';
image.parentElement.style.display = 'block';
return true;
}
return false;
});
})
@marlonwanger
marlonwanger / Teste.js
Created March 29, 2021 22:22
Mostrando ArrowFunctions
Sem Arrow Functions.
new MutationObserver(function(mutations) {
}).observe(iframe, {
atributes: true,
atributeFilter: ['src'],
attributeOldValue: true
});
@marlonwanger
marlonwanger / LoadingIframe.js
Created March 29, 2021 22:19
Parte1LoadingIframe
new MutationObserver((mutations) => {
mutations.some((mutation) => {
}).observe(iframe, {
atributes: true,
atributeFilter: ['src'],
attributeOldValue: true
});