Forum Home
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Popular

    [Dev] Documenting Feathercoin Specific Software settings - Part 3

    Technical Development
    1
    33
    7051
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • wrapper
      wrapper Moderators last edited by wrapper

      Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

      Support fork history commit

      https://github.com/FeatherCoin/Feathercoin/commit/2ca14b4c772b5cd7e8b0e8f2b81e3ae9a3a6c87b

      src/qt/forms/intro.ui

       -      <string>Welcome to Bitcoin Core.</string>
       +      <string>Welcome to Feathercoin Core.</string>
      

      Code replaced name, convert to be by translations?

       +      <string>As this is the first time the program is launched, you can choose where Feathercoin Core will store its data.</string>
      

      Replace Bitcoin code

       +      <string>Feathercoin Core will download and store a copy of the Feathercoin block chain. At least %1GB of data will be stored in this directory, and it will grow over time. The wallet will also be stored in this directory.</string>
      

      Replace Bitcoin code name change

      1 Reply Last reply Reply Quote 1
      • wrapper
        wrapper Moderators last edited by wrapper

        Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

        Support fork history commit

        https://github.com/FeatherCoin/Feathercoin/commit/2ca14b4c772b5cd7e8b0e8f2b81e3ae9a3a6c87b

        src/qt/intro.cpp

        +                QMessageBox::critical(0, tr("Feathercoin"),
        

        Bitcoin code replaced name change

        1 Reply Last reply Reply Quote 1
        • wrapper
          wrapper Moderators last edited by wrapper

          Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

          Support fork history commit

          https://github.com/FeatherCoin/Feathercoin/commit/2ca14b4c772b5cd7e8b0e8f2b81e3ae9a3a6c87b

          src/qt/openuridialog.cpp

           +    ui->uriEdit->setPlaceholderText("feathercoin:");
          
           +    ui->uriEdit->setText("feathercoin:?r=" + QUrl::toPercentEncoding(fileUri.toString()));
          

          Code replaced name change

          1 Reply Last reply Reply Quote 1
          • wrapper
            wrapper Moderators last edited by

            Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

            Fix compile error commit

            https://github.com/FeatherCoin/Feathercoin/commit/ce54ff5609afb5b7cace591a6a0c7ba500f15ac1

            src/base58.cpp

             + // Copyright (c) 2014 The Bitcoin developers
             + // Distributed under the MIT/X11 software license, see the accompanying
             + // file COPYING or http://www.opensource.org/licenses/mit-license.php.
             + 
             + #include "base58.h"
             + 
             + #include "hash.h"
             + #include "uint256.h"
             + 
             + #include <assert.h>
             + #include <stdint.h>
             + #include <string.h>
             + #include <vector>
             + #include <string>
             + #include <boost/variant/apply_visitor.hpp>
             + #include <boost/variant/static_visitor.hpp>
             + 
             + /* All alphanumeric characters except for "0", "I", "O", and "l" */
             + static const char* pszBase58 = 
            

            New files start. 273 lines

            1 Reply Last reply Reply Quote 0
            • wrapper
              wrapper Moderators last edited by wrapper

              Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

              Fix compile error commit

              https://github.com/FeatherCoin/Feathercoin/commit/ce54ff5609afb5b7cace591a6a0c7ba500f15ac1

              src/base58.h

              New file

                // Why base-58 instead of standard base-64 encoding?
                // - Don't want 0OIl characters that look the same in some fonts and
                //      could be used to create visually identical looking account numbers.
                // - A string with non-alphanumeric characters is not as easily accepted as an account number.
                // - E-mail usually won't line-break if there's no punctuation to break at.
                // - Double-clicking selects the whole number as one word if it's all alphanumeric.
                //
                #ifndef BITCOIN_BASE58_H
                #define BITCOIN_BASE58_H
              
                #include "chainparams.h"
                #include "key.h"
                #include "script.h"
              
                #include <string>
                #include <vector>
              
                /**
                 * Encode a byte sequence as a base58-encoded string.
                 * pbegin and pend cannot be NULL, unless both are.
                */
               std::string EncodeBase58(const unsigned char* pbegin, const unsigned char* pend);
              

              New file .150 starts.here, where from?

              1 Reply Last reply Reply Quote 0
              • wrapper
                wrapper Moderators last edited by

                Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                Fix compile error commit

                https://github.com/FeatherCoin/Feathercoin/commit/ce54ff5609afb5b7cace591a6a0c7ba500f15ac1

                src/mruset.h

                 +    void clear() { set.clear(); queue.clear(); }
                

                Add code

                1 Reply Last reply Reply Quote 0
                • wrapper
                  wrapper Moderators last edited by wrapper

                  Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                  Fix compile error commit

                  https://github.com/FeatherCoin/Feathercoin/commit/ce54ff5609afb5b7cace591a6a0c7ba500f15ac1

                  src/netbase.h

                    -#ifdef USE_IPV6
                  

                  2 if defs for iPv6 Code removed

                    +/** Return readable error string for a network error code */
                    +std::string NetworkErrorString(int err);
                  

                  Code added

                  1 Reply Last reply Reply Quote 0
                  • wrapper
                    wrapper Moderators last edited by wrapper

                    Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                    Fix compile error commit

                    https://github.com/FeatherCoin/Feathercoin/commit/ce54ff5609afb5b7cace591a6a0c7ba500f15ac1

                    src/rpcmisc.cpp

                     -    obj.push_back(Pair("timeoffset",    (boost::int64_t)GetTimeOffset()));
                     +    obj.push_back(Pair("timeoffset",    GetTimeOffset()));
                    
                     -    obj.push_back(Pair("timeoffset",    (boost::int64_t)GetTimeOffset()));
                     +    obj.push_back(Pair("timeoffset",    GetTimeOffset()));
                    
                     -      obj.push_back(Pair("unlocked_until", (boost::int64_t)nWalletUnlockTime));
                     +      obj.push_back(Pair("unlocked_until", nWalletUnlockTime));
                    
                     -     CScript _createmultisig(const Array& params)
                     +    CScript _createmultisig_redeemScript(const Array& params)
                    

                    Code replaced

                     + 
                     +     if (result.size() > MAX_SCRIPT_ELEMENT_SIZE)
                     +         throw runtime_error(
                     +                 strprintf("redeemScript exceeds size limit: %d > %d", result.size(), MAX_SCRIPT_ELEMENT_SIZE));
                     + 
                    

                    Additional code

                     -    CScript inner = _createmultisig(params);
                     +    CScript inner = _createmultisig_redeemScript(params);
                    

                    Code replaced

                     +            "verifymessage \"feathercoinaddress\" \"signature\" \"message\"\n"
                    
                     +            "1. \"feathercoinaddress\"  (string, required) The feathercoin address to use for the signature.\n"
                    

                    Code replaced name change

                    1 Reply Last reply Reply Quote 0
                    • wrapper
                      wrapper Moderators last edited by wrapper

                      Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                      Fix compile error commit

                      https://github.com/FeatherCoin/Feathercoin/commit/ce54ff5609afb5b7cace591a6a0c7ba500f15ac1

                      src/rpcprotocol.cpp

                       -    char buffer[64];
                       -    time(&now);
                       -    time_t now;
                       -    struct tm* now_gmt = gmtime(&now);
                       -    string locale(setlocale(LC_TIME, NULL));
                       -    setlocale(LC_TIME, "C"); // we want POSIX (aka "C") weekday/month strings
                       -    strftime(buffer, sizeof(buffer), "%a, %d %b %Y %H:%M:%S +0000", now_gmt);
                       -    setlocale(LC_TIME, locale.c_str());
                       -    return string(buffer);
                      

                      Code replaced

                        +    return DateTimeStrFormat("%a, %d %b %Y %H:%M:%S +0000", GetTime());
                      

                      Code added to replace code

                       -            "Content-Length: %"PRIszu"\r\n"
                       +            "Content-Length: %u\r\n"
                      

                      Code replaced

                      1 Reply Last reply Reply Quote 0
                      • wrapper
                        wrapper Moderators last edited by wrapper

                        Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                        Fix compile error commit

                        https://github.com/FeatherCoin/Feathercoin/commit/ce54ff5609afb5b7cace591a6a0c7ba500f15ac1

                        src/serialize.h

                         -#define FLATDATA(obj)  REF(CFlatData((char*)&(obj), (char*)&(obj+  sizeof(obj)))
                         + #define FLATDATA(obj) REF(CFlatData((char*)&(obj), (char*)&(obj)+  sizeof(obj)))
                         -#define VARINT(obj)    REF(WrapVarInt(REF(obj)))
                         + #define VARINT(obj) REF(WrapVarInt(REF(obj)))
                         + #define LIMITED_STRING(obj,n) REF(LimitedString< n >(REF(obj)))
                        

                        Replace code

                         + template<size_t Limit>
                         + class LimitedString
                         + {
                         + protected:
                         +     std::string& string;
                         + public:
                         +     LimitedString(std::string& string) : string(string) {}
                         + 
                         +     template<typename Stream>
                         +     void Unserialize(Stream& s, int, int=0)
                         +     {
                         +         size_t size = ReadCompactSize(s);
                         +         if (size > Limit) {
                         +             throw std::ios_base::failure("String length limit exceeded");
                         +         }
                         +         string.resize(size);
                         +         if (size != 0)
                         +             s.read((char*)&string[0], size);
                         +     }
                         + 
                         +     template<typename Stream>
                         +     void Serialize(Stream& s, int, int=0) const
                         +     {
                         +         WriteCompactSize(s, string.size());
                         +         if (!string.empty())
                         +             s.write((char*)&string[0], string.size());
                         +     }
                         + 
                         +     unsigned int GetSerializeSize(int, int=0) const
                         +     {
                         +         return GetSizeOfCompactSize(string.size())      +  string.size();
                         +     }
                         + };
                         + 
                        

                        Added code

                         -     {
                                   setstate(std::ios::failbit, "CDataStream::ignore() : end of data");
                        
                         -         nSize = vch.size()      - nReadPos;
                         -      }
                        

                        Code removed

                        1 Reply Last reply Reply Quote 0
                        • wrapper
                          wrapper Moderators last edited by wrapper

                          Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                          Fix compile error 2 - commit

                          https://github.com/FeatherCoin/Feathercoin/commit/eca6f424ab7d927436a38af434ad357946c8219c

                          src/rpcblockchain.cpp

                           +#include "checkpoints.h"
                          

                          Additional code

                           -    result.push_back(Pair("time", (boost::int64_t)block.GetBlockTime()));
                           +     result.push_back(Pair("time", block.GetBlockTime()));
                           -    result.push_back(Pair("nonce", (boost::uint64_t)block.nNonce));
                           +     result.push_back(Pair("nonce", (uint64_t)block.nNonce));
                          
                           -            info.push_back(Pair("time", (boost::int64_t)e.GetTime()));
                           +            info.push_back(Pair("time", e.GetTime()));
                          
                           -    ReadBlockFromDisk(block, pblockindex);
                           + 
                           +     if(!ReadBlockFromDisk(block, pblockindex))
                           +         throw JSONRPCError(RPC_INTERNAL_ERROR, "Can't read block from disk");
                          
                           -        ret.push_back(Pair("height", (boost::int64_t)stats.nHeight));
                           +         ret.push_back(Pair("height", (int64_t)stats.nHeight));
                          
                           -        ret.push_back(Pair("transactions", (boost::int64_t)stats.nTransactions));
                           +         ret.push_back(Pair("transactions", (int64_t)stats.nTransactions));
                           -        ret.push_back(Pair("txouts", (boost::int64_t)stats.nTransactionOutputs));
                           +         ret.push_back(Pair("txouts", (int64_t)stats.nTransactionOutputs));
                           -        ret.push_back(Pair("bytes_serialized", (boost::int64_t)stats.nSerializedSize));
                           +         ret.push_back(Pair("bytes_serialized", (int64_t)stats.nSerializedSize));
                          

                          Replace code

                           + Value getblockchaininfo(const Array& params, bool fHelp)
                           + {
                           +     if (fHelp || params.size() != 0)
                           +         throw runtime_error(
                           +             "getblockchaininfo\n"
                           +             "Returns an object containing various state info regarding block chain processing.\n"
                           +             "\nResult:\n"
                           +             "{\n"
                           +             "  \"chain\": \"xxxx\",        (string) current chain (main, testnet3, regtest)\n"
                           +             "  \"blocks\": xxxxxx,         (numeric) the current number of blocks processed in the server\n"
                           +             "  \"bestblockhash\": \"...\", (string) the hash of the currently best block\n"
                           +             "  \"difficulty\": xxxxxx,     (numeric) the current difficulty\n"
                           +             "  \"verificationprogress\": xxxx, (numeric) estimate of verification progress [0..1]\n"
                           +             "  \"chainwork\": \"xxxx\"     (string) total amount of work in active chain, in hexadecimal\n"
                           +             "}\n"
                           +             "\nExamples:\n"
                           +                  +  HelpExampleCli("getblockchaininfo", "")
                           +                  +  HelpExampleRpc("getblockchaininfo", "")
                           +         );
                           + 
                           +     proxyType proxy;
                           +     GetProxy(NET_IPV4, proxy);
                           + 
                           +     Object obj;
                           +     std::string chain = Params().DataDir();
                           +     if(chain.empty())
                           +         chain = "main";
                           +     obj.push_back(Pair("chain",         chain));
                           +     obj.push_back(Pair("blocks",        (int)chainActive.Height()));
                           +     obj.push_back(Pair("bestblockhash", chainActive.Tip()->GetBlockHash().GetHex()));
                           +     obj.push_back(Pair("difficulty",    (double)GetDifficulty()));
                           +     obj.push_back(Pair("verificationprogress", Checkpoints::GuessVerificationProgress(chainActive.Tip())));
                           +     obj.push_back(Pair("chainwork",     chainActive.Tip()->nChainWork.GetHex()));
                           +     return obj;
                           + }
                          

                          Additional code for getblockchaininfo

                          1 Reply Last reply Reply Quote 0
                          • wrapper
                            wrapper Moderators last edited by wrapper

                            Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                            Fix compile error 2 - commit

                            https://github.com/FeatherCoin/Feathercoin/commit/eca6f424ab7d927436a38af434ad357946c8219c

                            src/rpcwallet.cpp

                             -        entry.push_back(Pair("blocktime", (boost::int64_t)(mapBlockIndex[wtx.hashBlock]->nTime)));
                             +        entry.push_back(Pair("blocktime", (int64_t)(mapBlockIndex[wtx.hashBlock]->nTime)));
                            

                            Code replaced

                             -    entry.push_back(Pair("time", (boost::int64_t)wtx.GetTxTime()));
                             +     entry.push_back(Pair("time", wtx.GetTxTime()));
                             -    entry.push_back(Pair("timereceived", (boost::int64_t)wtx.nTimeReceived));
                             +     entry.push_back(Pair("timereceived", (int64_t)wtx.nTimeReceived));
                            
                             -            "\"transactionid\"  (string) The transaction id. (view at https://blockchain.info/tx/[transactionid])\n"
                             +             "\"transactionid\"  (string) The transaction id.\n"
                            
                             -            "\"transactionid\"        (string) The transaction id. (view at https://blockchain.info/tx/[transactionid])\n"
                             +             "\"transactionid\"        (string) The transaction id.\n"
                            
                             -            "                                    the number of addresses. See https://blockchain.info/tx/[transactionid]\n"
                             +             "                                    the number of addresses.\n"
                            
                             -extern CScript _createmultisig(const Array& params);
                             + extern CScript _createmultisig_redeemScript(const Array& params);
                            
                             -    CScript inner = _createmultisig(params);
                             +     CScript inner = _createmultisig_redeemScript(params);
                            
                             -        entry.push_back(Pair("time", (boost::int64_t)acentry.nTime));
                             +         entry.push_back(Pair("time", acentry.nTime));
                            
                             -            "    \"txid\": \"transactionid\", (string) The transaction id (see https://blockchain.info/tx/[transactionid]. Available \n"
                             +             "    \"txid\": \"transactionid\", (string) The transaction id. Available for 'send' and 'receive' category of transactions.\n"
                             -            "                                          for 'send' and 'receive' category of transactions.\n"
                            
                             -            "    \"txid\": \"transactionid\",  (string) The transaction id (see https://blockchain.info/tx/[transactionid]. Available for 'send' and 'receive' category of transactions.\n"
                             +             "  \"txid\" : \"transactionid\",   (string) The transaction id.\n"
                            
                             -            "Temporarily lock (lock=true) or unlock (lock=false) specified transaction outputs.\n"
                             +             "Temporarily lock (unlock=false) or unlock (unlock=true) specified transaction outputs.\n"
                            
                             -    obj.push_back(Pair("keypoololdest", (boost::int64_t)pwalletMain     ->GetOldestKeyPoolTime()));
                             +     obj.push_back(Pair("keypoololdest", pwalletMain     ->GetOldestKeyPoolTime()));
                            
                            
                             -        obj.push_back(Pair("unlocked_until", (boost::int64_t)nWalletUnlockTime));
                             +         obj.push_back(Pair("unlocked_until", nWalletUnlockTime));
                            

                            Code replaced

                            1 Reply Last reply Reply Quote 0
                            • wrapper
                              wrapper Moderators last edited by

                              Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                              Fix lost file - commit

                              https://github.com/FeatherCoin/Feathercoin/commit/1d396a14752fbe8120f4bebe0ebfaaa69fba3531

                              src/qt/locale/bitcoin_mn.ts

                              Translation file complete

                              1 Reply Last reply Reply Quote 0
                              • wrapper
                                wrapper Moderators last edited by

                                Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                                Fix lost files 2- commit

                                https://github.com/FeatherCoin/Feathercoin/commit/388d6bdb1cfd96b8634b5c7f5f8b392990abe7d2

                                src/qt/guiutil.h

                                 + 
                                 +     // Replace invalid default fonts with known good ones
                                 +     void SubstituteFonts();
                                 + 
                                

                                Additional code

                                1 Reply Last reply Reply Quote 0
                                • wrapper
                                  wrapper Moderators last edited by

                                  Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                                  Fix lost files 2- commit

                                  https://github.com/FeatherCoin/Feathercoin/commit/388d6bdb1cfd96b8634b5c7f5f8b392990abe7d2

                                  src/qt/optionsmodel.h

                                   +        ThirdPartyTxUrls,       // QString
                                  
                                   +    QString getThirdPartyTxUrls() { return strThirdPartyTxUrls; }
                                  
                                  +    QString strThirdPartyTxUrls;
                                  

                                  Additional code

                                  1 Reply Last reply Reply Quote 0
                                  • wrapper
                                    wrapper Moderators last edited by

                                    Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                                    Fix lost files 2- commit

                                    https://github.com/FeatherCoin/Feathercoin/commit/388d6bdb1cfd96b8634b5c7f5f8b392990abe7d2

                                    src/qt/rpcconsole.h

                                     -    void setNumBlocks(int count, int countOfPeers);
                                     +    void setNumBlocks(int count);
                                    

                                    Code replaced

                                    1 Reply Last reply Reply Quote 0
                                    • wrapper
                                      wrapper Moderators last edited by wrapper

                                      Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                                      Fix lost files 2- commit

                                      https://github.com/FeatherCoin/Feathercoin/commit/388d6bdb1cfd96b8634b5c7f5f8b392990abe7d2

                                      src/qt/transactiontablemodel.cpp

                                       -#include <QTimer>
                                      

                                      Code removed

                                       -            LOCK(wallet->cs_wallet);
                                       +            LOCK2(cs_main, wallet->cs_wallet);
                                      

                                      Lock code replaced twice

                                       +             // Get required locks upfront. This avoids the GUI from getting
                                       +             // stuck if the core is holding the locks for a longer time - for
                                       +             // example, during a wallet rescan.
                                       +             //
                                      

                                      Additional comments

                                      -            if(rec->statusUpdateNeeded())
                                      +             TRY_LOCK(cs_main, lockMain);
                                      +             if(lockMain)
                                               {
                                       +                 TRY_LOCK(wallet->cs_wallet, lockWallet);
                                       +                 if(lockWallet && rec->statusUpdateNeeded())
                                      
                                               {
                                       -                     LOCK(wallet->cs_wallet); 
                                      

                                      Code replaced

                                       -            LOCK(wallet->cs_wallet);
                                       +            LOCK2(cs_main, wallet->cs_wallet);
                                      

                                      Lock code replaced

                                       -        priv(new TransactionTablePriv(wallet, this)),
                                       +        priv(new TransactionTablePriv(wallet, this))
                                       -        cachedNumBlocks(0)
                                      

                                      Code replaced

                                       -    QTimer *timer = new QTimer(this);
                                       -    connect(timer, SIGNAL(timeout()), this, SLOT(updateConfirmations()));
                                       -    timer->start(MODEL_UPDATE_DELAY);
                                       -
                                      

                                      Code removed

                                       -    {
                                       -        cachedNumBlocks = chainActive.Height();
                                       -        // Blocks came in since last poll.
                                       -        // Invalidate status (number of confirmations) and (possibly) description
                                       -        //  for all rows. Qt is smart enough to only actually request the data for the
                                       -        //  visible rows.
                                       -        emit dataChanged(index(0, Status), index(priv     ->size()     -1, Status));
                                       -        emit dataChanged(index(0, ToAddress), index(priv     ->size()     -1, ToAddress));
                                       -    } 
                                      

                                      Code removed

                                       +     // Blocks came in since last poll.
                                       +     // Invalidate status (number of confirmations) and (possibly) description
                                       +     //  for all rows. Qt is smart enough to only actually request the data for the
                                       +     //  visible rows.
                                       +     emit dataChanged(index(0, Status), index(priv     ->size()     -1, Status));
                                       +     emit dataChanged(index(0, ToAddress), index(priv     ->size()     -1, ToAddress));
                                      

                                      Code replaces removed code

                                       +    case TxHashRole:
                                       +        return QString::fromStdString(rec->hash.ToString());
                                      

                                      Additional code

                                      1 Reply Last reply Reply Quote 1
                                      • wrapper
                                        wrapper Moderators last edited by

                                        Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                                        Fix lost files 2- commit

                                        https://github.com/FeatherCoin/Feathercoin/commit/388d6bdb1cfd96b8634b5c7f5f8b392990abe7d2

                                        src/qt/transactiontablemodel.h

                                        Wallet transaction screen.

                                         +        /** Transaction hash */
                                         +        TxHashRole,
                                        

                                        Code added

                                        -    int cachedNumBlocks;
                                        

                                        Code removed

                                        1 Reply Last reply Reply Quote 0
                                        • wrapper
                                          wrapper Moderators last edited by wrapper

                                          Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                                          Fix lost files 2- commit

                                          https://github.com/FeatherCoin/Feathercoin/commit/388d6bdb1cfd96b8634b5c7f5f8b392990abe7d2

                                          src/qt/winshutdownmonitor.cpp

                                          A new file? where from?

                                           + // Copyright (c) 2014 The Bitcoin developers
                                           + // Distributed under the MIT/X11 software license, see the accompanying
                                           + // file COPYING or http://www.opensource.org/licenses/mit-license.php.
                                           + 
                                           + #include "winshutdownmonitor.h"
                                           + 
                                           + #if defined(Q_OS_WIN) && QT_VERSION >= 0x050000
                                           + #include "init.h"
                                           + 
                                           + #include <windows.h>
                                           + 
                                           + #include <QDebug>
                                           + 
                                           + // If we don't want a message to be processed by Qt, return true and set result to
                                           + // the value that the window procedure should return. Otherwise return false.
                                           + bool WinShutdownMonitor::nativeEventFilter(const QByteArray &eventType, void *pMessage, long *pnResult)
                                           + {
                                          

                                          Start of code, 57 lines of code

                                          1 Reply Last reply Reply Quote 0
                                          • wrapper
                                            wrapper Moderators last edited by wrapper

                                            Feathercoin specific changes made to convert Bitcoin to FTC 0.9.6.*

                                            Fix lost files 2- commit

                                            https://github.com/FeatherCoin/Feathercoin/commit/388d6bdb1cfd96b8634b5c7f5f8b392990abe7d2

                                            src/qt/winshutdownmonitor.h

                                            A new file? where from?

                                             + // Copyright (c) 2014 The Bitcoin developers
                                             + // Distributed under the MIT/X11 software license, see the accompanying
                                             + // file COPYING or http://www.opensource.org/licenses/mit-license.php.
                                             + 
                                             + #ifndef WINSHUTDOWNMONITOR_H
                                             + #define WINSHUTDOWNMONITOR_H
                                             + 
                                             + #ifdef WIN32
                                             + #include <QByteArray>
                                             + #include <QString>
                                             + 
                                             + #if QT_VERSION >= 0x050000
                                             + #include <windef.h> // for HWND
                                             + 
                                             + #include <QAbstractNativeEventFilter>
                                             + 
                                             + class WinShutdownMonitor : public QAbstractNativeEventFilter
                                             + {
                                             + public:
                                             +     /** Implements QAbstractNativeEventFilter interface for processing Windows messages */
                                             +     bool nativeEventFilter(const QByteArray &eventType, void *pMessage, long *pnResult);
                                             + 
                                             +     /** Register the reason for blocking shutdown on Windows to allow clean client exit */
                                             +     static void registerShutdownBlockReason(const QString& strReason, const HWND& mainWinId);
                                             + };
                                             + #endif
                                             + #endif
                                             + 
                                             + #endif // WINSHUTDOWNMONITOR_H
                                            

                                            Code to replacement / new file

                                            1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post